detail.php
OW2 Forge: Detail: 306655 WBWML <Data> values sent by Sagem myX6-2 are incorrectly decoded

Advanced - Powered by Google


   
Log In
New Account
  
 
Home
My Page
Project Tree
Project Openings
Funambol
          
 
 
Summary
Tracker
Lists
Tasks
Docs
News
CVS
Files
                
 

Tracker: Bugs

Submit New | Browse | Admin | ExportToXml

[ #306655 ] WBWML values sent by Sagem myX6-2 are incorrectly decoded

Date:
2007-02-12 10:54
Priority:
5
Submitted By:
MJ (mjmj)
Assigned To:
Stefano Nichele (nichele)
Category:
transport
State:
Open
Summary:
WBWML <Data> values sent by Sagem myX6-2 are incorrectly decoded

Detailed description:
A problem occurs during the unmarshalling of the first wbxml message sent by the Sagem myX6-2 because some &lt;Data&gt; field values are base64 encoded when they should not : [7 févr. 2007 15:15:15][funambol.server] SEVERE: Error unmarshalling message:Non-digit in number value (line 173, col 79) [7 févr. 2007 15:15:15][funambol.server] FINER: THROW org.jibx.runtime.JiBXException: Non-digit in number value (line 173, col 79) at org.jibx.runtime.impl.UnmarshallingContext.parseContentInt(UnmarshallingContext.java:1027) at org.jibx.runtime.impl.UnmarshallingContext.parseElementInt(UnmarshallingContext.java:1312) at com.funambol.framework.core.Alert.JiBX_binding_unmarshal_3_0(Alert.java) at com.funambol.framework.core.JiBX_bindingAlert_access.unmarshal() at com.funambol.framework.core.JiBX_bindingAbstractCommand_access.unmarshal() at com.funambol.framework.core.JiBX_MungeAdapter.JiBX_binding_unmarshal_1_0() at com.funambol.framework.core.SyncBody.JiBX_binding_unmarshal_1_0(SyncBody.java) at com.funambol.framework.core.JiBX_bindingSyncBody_access.unmarshal() at com.funambol.framework.core.SyncML.JiBX_binding_unmarshal_1_0(SyncML.java) at com.funambol.framework.core.JiBX_bindingSyncML_access.unmarshal() at org.jibx.runtime.impl.UnmarshallingContext.unmarshalElement(UnmarshallingContext.java:2644) at org.jibx.runtime.impl.UnmarshallingContext.unmarshalDocument(UnmarshallingContext.java:2827) at com.funambol.server.engine.SyncAdapter.convert(SyncAdapter.java:512) at com.funambol.server.engine.SyncAdapter.processWBXMLMessage(SyncAdapter.java:300) In fact, the pb comes from the xml message generated by the com.funambol.framework.tools.WBXMLTools class : The parseWBXML(parser,inTag) uses two flags (inTag[4] and inTag[5]) in order to manage base64 encoding and md5 encryption in &lt;Data&gt; values when a &lt;Meta&gt; tags is set. But the flags are never reseted and are consequently used for following &lt;Data&gt; values without associated &lt;Meta&gt; tag. And this is what happened with the Sagem device : the flags are set when processing the credentials: &lt;Cred&gt; &lt;Meta&gt; &lt;Type&gt;syncml:auth-md5&lt;/Type&gt; &lt;/Meta&gt; &lt;Data&gt;25fbJSxd8P3mpKGNuejnjA==&lt;/Data&gt; &lt;/Cred&gt; inTag[4]=true (true because the authentification is an md5 one), inTag[5]=false (false because no b64 declared). Because of this 2 values, the method parseWBXML encode the data value with base64 encoder. But in the next data tag within the following Alert: &lt;Alert&gt; &lt;CmdID&gt;1001&lt;/CmdID&gt; &lt;Data&gt;MjAw&lt;/Data&gt; &lt;Item&gt; &lt;Target&gt;&lt;LocURI&gt;./card&lt;/LocURI&gt;&lt;/Target&gt; &lt;Source&gt;&lt;LocURI&gt;./card&lt;/LocURI&gt;&lt;/Source&gt; &lt;Meta&gt; &lt;Anchor&gt; &lt;Last&gt;20051213T115015Z&lt;/Last&gt; &lt;Next&gt;20070207T151510Z&lt;/Next&gt; &lt;/Anchor&gt; &lt;MaxObjSize&gt;4096&lt;/MaxObjSize&gt; &lt;/Meta&gt; &lt;/Item&gt; &lt;/Alert&gt; There is no associated Meta tag, but as the inTag[4] and inTag[5] flags have not been reseted, the content is unappropriately b64 encoded.

Add A Comment:

Please login

Followup

Message
Date: 2007-02-28 08:34
Sender: nichele
Collegato: no 
user_id=2381

Hi mjmj,
in attachment my proposal...are you able to try it  ?
This would be very useful.

Thanks a lot
Ste
Date: 2007-02-27 13:56
Sender: mjmj
connecté 
user_id=11584

We have rebuilt the server with the attached patched version
of WBXMLTools and the Sagem myX6-2 works fine with it.

regards,

MJ
Date: 2007-02-27 13:37
Sender: nichele
Collegato: no 
user_id=2381

Do you have any verified patch for that ? 
Date: 2007-02-22 08:52
Sender: mjmj
connecté 
user_id=11584

it is related to DS server.
Date: 2007-02-22 08:42
Sender: nichele
Collegato: no 
user_id=2381

Hi (mjmj),
is it relative to DS Server or DM Server ?

thanks
Date: 2007-02-21 14:07
Sender: cristiano
Logged In: YES 
user_id=11773

Accepted.  Eligible for the Bag-a-Bug Program. 1 point.

Bug inserted in Bugzilla too (2063).

Attached Files:

Name Description Download
WBXMLTools.java patch for Sagem Download
WBXMLTools.java Patch proposed by Funambol Download

Changes:

Resource id #66listtable
File Added File Added resolution_id
Field Old Value Date By
File Added849: WBXMLTools.java2007-02-28 08:32nichele
File Added847: WBXMLTools.java2007-02-27 13:56mjmj
resolution_idNone2007-02-21 14:07cristiano

Copyright © 1999-2008, OW2 Consortium | contact | You've got a problem ? Please report an issue using your OW2 forge account credentials