Author: Pekka Riikonen <priikone@silcnet.org>
- Copyright (C) 2001 - 2003, 2006 Pekka Riikonen
+ Copyright (C) 2001 - 2007 Pekka Riikonen
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
* SYNOPSIS
*
* SilcBuffer silc_key_agreement_payload_encode(char *hostname,
- * SilcUInt32 port);
+ * SilcUInt16 protocol,
+ * SilcUInt16 port);
*
* DESCRIPTION
*
- * Encodes the Key Agreement protocol and returns the encoded buffer
+ * Encodes the Key Agreement payload and returns the encoded buffer.
+ * The `protocol' is 0 for TCP and 1 for UDP.
*
***/
SilcBuffer silc_key_agreement_payload_encode(const char *hostname,
- SilcUInt32 port);
+ SilcUInt16 protocol,
+ SilcUInt16 port);
/****f* silccore/SilcAuthAPI/silc_key_agreement_payload_free
*
*
* DESCRIPTION
*
- * Frees the Key Agreement protocol and all data in it.
+ * Frees the Key Agreement payload and all data in it.
*
***/
void silc_key_agreement_payload_free(SilcKeyAgreementPayload payload);
***/
char *silc_key_agreement_get_hostname(SilcKeyAgreementPayload payload);
+/****f* silccore/SilcAuthAPI/silc_key_agreement_get_protocol
+ *
+ * SYNOPSIS
+ *
+ * SilcUInt16
+ * silc_key_agreement_get_protocol(SilcKeyAgreementPayload payload);
+ *
+ * DESCRIPTION
+ *
+ * Returns the protocol in the payload. The protocol is either TCP (0)
+ * or UDP (1).
+ *
+ ***/
+SilcUInt16 silc_key_agreement_get_protocol(SilcKeyAgreementPayload payload);
+
/****f* silccore/SilcAuthAPI/silc_key_agreement_get_port
*
* SYNOPSIS
*
- * SilcUInt32 silc_key_agreement_get_port(SilcKeyAgreementPayload payload);
+ * SilcUInt16 silc_key_agreement_get_port(SilcKeyAgreementPayload payload);
*
* DESCRIPTION
*
* the SILC Key Exchange protocol.
*
***/
-SilcUInt32 silc_key_agreement_get_port(SilcKeyAgreementPayload payload);
+SilcUInt16 silc_key_agreement_get_port(SilcKeyAgreementPayload payload);
#endif