Bugs: Browse | Submit New | Admin

[#17880] WSS4R crashes on incomplete timestamps received

Date:
2008-02-08 01:59
Priority:
3
Submitted By:
Wesha the Leopard (wesha)
Assigned To:
Roland Schmitt (schmitr3)
Category:
None
State:
Open
Summary:
WSS4R crashes on incomplete timestamps received

Detailed description
Some wonky WSS implementations submit an incomplete timestamp:

<soap:Header>
  <wsse:Security xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd&q
uot;>
    <wsu:Timestamp xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd
" wsu:Id="Timestamp-23256120">
      <wsu:Created>2008-02-07T23:47:19.552Z</wsu:Created>
    </wsu:Timestamp>
  </wsse:Security>
</soap:Header>

that crashes WSS4R:

NoMethodError: undefined method `text' for nil:NilClass
        from /home/ubuntu/p4/cnuapp/bug/5717/vendor/gems/wss4r-0.5/lib/wss4r/security/xml/timestamp.rb:30:in
`unprocess'
        from /home/ubuntu/p4/cnuapp/bug/5717/vendor/gems/wss4r-0.5/lib/wss4r/security/xml/security.rb:29:in `unprocess'
        from /home/ubuntu/p4/cnuapp/bug/5717/vendor/gems/wss4r-0.5/lib/wss4r/security/security.rb:143:in
`process_document_unmarshal'

Need to add nil checking.

Add A Comment: Notepad

Please login


Followup

No Followups Have Been Posted

Attached Files:

Name Description Download
patch Patch that solves the crash (+fixing whitespace formatting) Download

Changes:

Field Old Value Date By
File Added3335: patch2008-02-08 02:16wesha
assigned_tonone2008-02-08 01:59wesha