none
[MS-NLMP] sealing & signing qustion RRS feed

  • Question

  • Hello

    I am trying to implement [MS-NLMP] examples. And I can't get expected sealing and signed message.

    4.2.2.4 GSS_WrapEx Examples
    The output message data and signature is created using SEAL() specified in section 3.4.3. And on this step I get wrong value.

    According to 3.4.3 Set Sealed message to RC4(Handle, Message)

    According to 3.4.5.3 SEALKEY:

    If (NTLMSSP_NEGOTIATE_EXTENDED_SESSIONSECURITY flag is set in NegFlg) ...

    ElseIf (NTLMSSP_NEGOTIATE_56 flag is set in NegFlg)
        Set SealKey to ConcatenationOf(RandomSessionKey[0..6], 0xA0)

     

    So SealKey == 55555555555555A0

    Then according to 3.1.5.1.2:

    RC4Init(ClientHandle, ClientSealingKey)

    And then if I do RC4(Handle, Message) I get the following:

    1EA99FA44E987C38CCE9CFF08D9B862D6DA7 instead of 56FE04D861F9319AF0D7238A2E3B4D457FB8

    So, can you please help me and tell what am I doing wrong.

    Thanks, Pavel


    Павел
    Tuesday, October 25, 2011 9:07 AM

Answers

  • Hi, Pavel,

     

       I wrote a simple test program to verify the sample in MS-NLMP.  Using the existing documentation, I got the same result as you.    I then confirmed that there is a problem with the documentation for SEALKEY in section 3.4.5.3.   In this case, the SEALKEY should be the RandomSessionKey itself instead of padding to just 8 bytes.  So in the example,  the SEALKEY should be 16 bytes of 0x55.   Once I use this SEALKEY,  I can get the correct output 56FE04D861F9319AF0D7238A2E3B4D457FB8. 

      I filed a request to update the SEALKEY section in 3.4.5.3 of MS-NLMP.   It will appear in the future release of the document.

     

    Thanks for bring this into our attention.

     

    Hongwei


    Hongwei Sun -MSFT
    Monday, October 31, 2011 11:33 PM

All replies

  • Hi Pavel, thank you for your question. A member of the protocol documentation team will respond to you soon.


    Josh Curry (jcurry) | Escalation Engineer | Open Specifications Support Team
    Tuesday, October 25, 2011 3:37 PM
    Moderator
  • Hi, Pavel,

     

       I wrote a simple test program to verify the sample in MS-NLMP.  Using the existing documentation, I got the same result as you.    I then confirmed that there is a problem with the documentation for SEALKEY in section 3.4.5.3.   In this case, the SEALKEY should be the RandomSessionKey itself instead of padding to just 8 bytes.  So in the example,  the SEALKEY should be 16 bytes of 0x55.   Once I use this SEALKEY,  I can get the correct output 56FE04D861F9319AF0D7238A2E3B4D457FB8. 

      I filed a request to update the SEALKEY section in 3.4.5.3 of MS-NLMP.   It will appear in the future release of the document.

     

    Thanks for bring this into our attention.

     

    Hongwei


    Hongwei Sun -MSFT
    Monday, October 31, 2011 11:33 PM
  • Hello Hongwei

    Ok, thanks a lot

    ---

    Pavel.

     


    Павел
    Tuesday, November 1, 2011 12:50 PM