[抱歉我的英语] 我在连接用 python 开发的客户端 quckfix 时遇到问题。配置文件没有像我想要的那样响应。
如果我将路径(不正确的路径,强制错误)更改为文件 *.pem 并重新启动应用程序。该应用程序没有任何作用,只是保持正常运行。
就好像配置没有被读取
在本教程中提到:Python 实现的 QuickFix 不支持 SSL,这是真的吗?
这是用于在 Windows 中使用来自 http://www.quickfixengine.org/
的库快速修复的 python IO 实现[DEFAULT]
PersistMessages=Y
ConnectionType=initiator
UseDataDictionary=Y
StartTime=00:00:00
EndTime=23:59:00
FileStorePath=incoming
FileLogPath=outgoing
[SESSION]
SSLEnable=Y
SSLProtocol=TLSv1
ClientCertificateFil=C:\python\pyarb\cert\cert.pem
ClientCertificateKeyFile=C:\python\pyarb\cert\key.pem
StartTime=14:00:00
SenderCompID=AGENT
TargetCompID=FIX
EndTime=00:00:00
ConnectionType=initiator
ApplVerID=9
BeginString=FIXT.1.1
DefaultApplVerID=9
TransportDataDictionary=quickfix_dicts\FIX50SP1.xml
AppDataDictionary=quickfix_dicts\FIX50SP1.xml
DataDictionary=quickfix_dicts\FIX50SP1.xml
SocketConnectPort=xxxx
SocketConnectHost=xxx.xxx.xxx.xxx
HeartBtInt=30
ReconnectInterval=30
ResetOnLogon=Y
ResetOnLogout=Y
ResetOnDisconnect=N
ResetSeqNumFlag=N
是的,截至撰写本文时,quickfix 不支持开箱即用的 SSL。您需要手动创建从您的计算机到需要 SSL 连接的主机的 SSL 隧道。您可以通过“隧道”来做到这一点。下面发布一些配置,希望能够解释如何设置。
隧道配置
log = append
output = <path where logs will be written>
[client]
client = yes
accept = <port of your choosing on the local machine for quickfix>
connect = <ssl host you want to connect to>:<port>
verifyPeer = yes
CAfile = <path of certification provided by SSL host>
checkHost = <ssl host you want to connect to>
debug = debug
下面的例子
log = append
output = /home/user/logs
[client]
client = yes
accept = 1589
connect = 5.854.17.45:446
verifyPeer = yes
CAfile = /etc/ssl/certs/ca-cert.pem
checkHost = 5.854.17.45
debug = debug
快速修复配置
[DEFAULT]
<Other relevant settings>
SocketConnectPort=1589
SocketConnectHost=localhost
[SESSION]
<Other relevant settings>
您的配置中有一个拼写错误: ClientCertificateFil=C:\python\pyar