Re: [Quickfix-developers] Logon passwords
Brought to you by:
orenmnero
From: <or...@qu...> - 2008-06-17 16:32:57
|
You should be checking the Logon message, not NewOrderSingle for passwords. --oren > I'm going to move my password checking out of the fromAdmin method to > the overloaded onMessage methods for each message to be > authenticated, like this: This will move password checking down from > the session level to the message level. > void QFApplication::onMessage(const FIX44::NewOrderSingle& m, const > SessionID & id) > { > Password pwd; m.getField(pwd); > if(pwd.getString() != string(dbpwd)) throw FIX::RejectLogon(); > } > Then on the sender side, I have this: > FIX44::NewOrderSingle o(...); > o.setField(FIX::Password("x0x0x0"); > FIX::Session::sendToTarget(o); > This compiles, but when it runs, I get this stuff on the acceptor side: > <20080617-16:20:57, FIX.4.4:MP->CLIENT, incoming> > (8=FIX. > 4.49=15035=D34=158249=CLIENT52=20080617-16:20:38.99156=MP1=314411=158138 > =4740=144=4070.3099223758654=255=MBI60=20080617-16:20:3864=F1554=x0x0x01 > 0=243) > <20080617-16:20:57, FIX.4.4:MP->CLIENT, event> > (Message 1582 Rejected: Tag not defined for this message type:554) > On Jun 17, 2008, at 10:18 AM, or...@qu... wrote: |