[sync] SyncML with Nokia 6230 - logs
Karsten Fourmont
fourmont at gmx.de
Sun Jul 11 07:49:28 PDT 2004
Hi Christian,
> <Data>
> Y2lsbGU6dGVzdA==
> </Data>
your XML seems to contain to much whitespace. It should look like
<Data>Y2lsbGU6dGVzdA==</Data>
or the current (very picky) implementation of SyncML gets confused.
Do you have the most recent version of
framework/XML_WBXML/WBXML/ContentHandler installed?
My phone doesn't send WBXML encoded data, so I can't figure out where
the whitespace is created.
We might have to add lots of trim()s to the code.
> If I make isAuthorized() to always return "true",
If you do something like this, better add
$this->_locName = xxxx;
this->password = yyyy
to your isAuthorized() function. Authorization is needed to access the
horde data.
> then the phone says
> "transmitting/receiving" and fails again, because horde does not find
> some anchors and wants to start slowsync. But this is the next story.
Starting a SlowSync is OK on the first sync run.
Bye
Karsten
Christian Cier-Zniewski wrote:
> Hi,
>
> Karsten Fourmont wrote:
>
>> Hi Christian,
>>
>> did your phone send the <cred>... stuff in <synchdr> or as part of
>> <syncbody>?
>>
>> For the later, you might want to give Joeri's patch a try:
>> http://lists.horde.org/archives/sync/Week-of-Mon-20040705/000403.html
>
>
> This is the answer from the phone after it is told to do auth-basic(only
> syncHdr):
> So it seems to be part of <synchdr>.
>
> I have added another log entry in state.php, which simply prints the
> username and password that is used to authenticate.
> Suprisingly the username seems to be empty all the time. Have a look
> below where I have put the relevant part of /tmp/horde.log
>
> If I make isAuthorized() to always return "true", then the phone says
> "transmitting/receiving" and fails again, because horde does not find
> some anchors and wants to start slowsync. But this is the next story. :-)
>
> Is it possible that there is a bug somewhere concering the username?
> $this->_locName in SyncML.php seems to contain the correct value(see
> below).
>
>
> Christian
>
> -------------------------------------------------------------------------
> function isAuthorized()
> {
>
> if (!$this->_isAuthorized) {
> $auth = &Auth::singleton($GLOBALS['conf']['auth']['driver']);
> $this->_isAuthorized = $auth->authenticate($this->_locName,
> array('password' => $this->_password));
> Horde::logMessage("SyncML: user: $this->_locName passwd:
> $this->_password", __FILE__, __LINE__, PEAR_LOG_DEBUG);
> }
> return $this->_isAuthorized;
>
> }
> ----------------------------------------------------------------------------
>
>
> ---------------------------------------------------------------------------
> <?xml version="1.0"?>
> <!DOCTYPE SyncML PUBLIC "-//SYNCML//DTD SyncML 1.1//EN"
> "http://www.syncml.org/docs/syncml_represent_v11_20020213.dtd">
> <SyncML xmlns="syncml:SYNCML1.1">
> <SyncHdr>
> <VerDTD>
> 1.1
> </VerDTD>
> <VerProto>
> SyncML/1.1
> </VerProto>
> <SessionID>
> 24
> </SessionID>
> <MsgID>
> 2
> </MsgID>
> <Target>
> <LocURI>
> http://xx.xx.xx.xx:8080/horde/rpc.php
> </LocURI>
> </Target>
> <Source>
> <LocURI>
> IMEI:3537670010xxxxx
> </LocURI>
> </Source>
> <Cred>
> <Meta>
> <Format xmlns="syncml:metinf">
> b64
> </Format>
> <Type xmlns="syncml:metinf">
> syncml:auth-basic
> </Type>
> </Meta>
> <Data>
> Y2lsbGU6dGVzdA==
> </Data>
> </Cred>
> <Meta>
> <MaxMsgSize xmlns="syncml:metinf">
> 3584
> </MaxMsgSize>
> </Meta>
> </SyncHdr>
More information about the sync
mailing list