Explorar o código

Merge pull request #424 from acplt/nonce

sending a 0-initalized nonce, fixes #420
Sten Grüner %!s(int64=9) %!d(string=hai) anos
pai
achega
673234752a
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/client/ua_client.c

+ 1 - 1
src/client/ua_client.c

@@ -187,7 +187,7 @@ static UA_StatusCode SecureChannelHandshake(UA_Client *client, UA_Boolean renew)
         opnSecRq.requestType = UA_SECURITYTOKENREQUESTTYPE_RENEW;
         opnSecRq.requestType = UA_SECURITYTOKENREQUESTTYPE_RENEW;
     } else {
     } else {
         opnSecRq.requestType = UA_SECURITYTOKENREQUESTTYPE_ISSUE;
         opnSecRq.requestType = UA_SECURITYTOKENREQUESTTYPE_ISSUE;
-        UA_SecureChannel_generateNonce(&client->channel.clientNonce);
+        UA_ByteString_init(&client->channel.clientNonce);
         UA_ByteString_copy(&client->channel.clientNonce, &opnSecRq.clientNonce);
         UA_ByteString_copy(&client->channel.clientNonce, &opnSecRq.clientNonce);
         opnSecRq.securityMode = UA_MESSAGESECURITYMODE_NONE;
         opnSecRq.securityMode = UA_MESSAGESECURITYMODE_NONE;
     }
     }