4

Im connecting to server using FIX protocol 4.4. Previously i used username and password for authentication.

Below is my configuration file

[DEFAULT]
ConnectionType=initiator
HeartBtInt=30
ReconnectInterval=30
ResetOnLogout=Y
ResetOnDisconnect=Y
FileStorePath=/tmp/msgs/
FileLogPath=/tmp/msgs/log/
StartTime=00:00:
EndTime=00:00:00
UseDataDictionary=N
SocketConnectHost=193.~.~.~
SocketNodelay=Y
PersistMessages=N

[SESSION]
BeginString=FIX.4.4
SenderCompID=abcdefh
TargetCompID=abcdefh
SocketConnectPort=7000
SenderSubID=abcdefh
Password=abcdefh

Now have to connect without using SenderSubID & password, but using private key. The keys are given in a pem file. I am giving sample of the code below

Bag Attributes localKeyID: 12 23 34 45 56 AX SC DV FV FB 12 23 34 45 56 AX SC DV FV FB subject=/CN=abcdefgh issuer=/C=GB/ST=London/L=London/O=DB/OU=GM/CN=demo fix dev -----BEGIN CERTIFICATE----- abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890 -----END CERTIFICATE----- Bag Attributes: subject=/C=GB/ST=London/L=London/O=DB/OU=GM/CN=demo fix dev issuer=/C=GB/ST=London/L=London/O=DB/OU=GM/CN=demo fix dev -----BEGIN CERTIFICATE----- abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890 -----END CERTIFICATE----- Bag Attributes localKeyID: 12 23 34 45 56 AX SC DV FV FB 12 23 34 45 56 AX SC DV FV FB Key Attributes: -----BEGIN RSA PRIVATE KEY----- abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqrstuvwxyz1234567890 -----END RSA PRIVATE KEY-----

I don't know how to proceed or what to do with this PEM file
I am new to java and FIX protocol

If anyone can explain the solution with java code, that would be very helpful

thanks

1 Answer 1

3

in order to connect with a counterparty with a PEM key, you have to install and config a new software.

In our production environment, we use sTunnel (https://www.stunnel.org/index.html) , a free software for tunnel and encrypt messages over a SSL layer.

Please download this sotware and read the manual for the config settings.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.