isis_send_pdu_bcast (struct isis_circuit *circuit, int level)
{
struct ether_header *eth;
- int written, buflen;
+ ssize_t written;
+ size_t buflen;
buflen = stream_get_endp (circuit->snd_stream) + LLC_LEN + ETHER_HDR_LEN;
if (buflen > sizeof (sock_buff))
{
- zlog_warn ("isis_send_pdu_bcast: sock_buff size %lu is less than "
- "output pdu size %d on circuit %s",
+ zlog_warn ("isis_send_pdu_bcast: sock_buff size %zu is less than "
+ "output pdu size %zu on circuit %s",
sizeof (sock_buff), buflen, circuit->interface->name);
return ISIS_WARNING;
}
/* Compute autentication value */
hmac_md5 (STREAM_DATA (lsp->pdu), stream_get_endp(lsp->pdu),
(unsigned char *) &passwd->passwd, passwd->len,
- (caddr_t) &hmac_md5_hash);
+ (unsigned char *) &hmac_md5_hash);
/* Copy the hash into the stream */
memcpy (STREAM_DATA (lsp->pdu) + lsp->auth_tlv_offset + 3,
hmac_md5_hash, ISIS_AUTH_MD5_SIZE);
/* Compute the digest */
hmac_md5 (STREAM_DATA (stream), stream_get_endp (stream),
(unsigned char *) &(local->passwd), local->len,
- (caddr_t) &digest);
+ (unsigned char *) &digest);
/* Copy back the authentication value after the check */
memcpy (STREAM_DATA (stream) + auth_tlv_offset + 3,
remote->passwd, ISIS_AUTH_MD5_SIZE);
hmac_md5 (STREAM_DATA (circuit->snd_stream),
stream_get_endp (circuit->snd_stream),
(unsigned char *) &circuit->passwd.passwd, circuit->passwd.len,
- (caddr_t) &hmac_md5_hash);
+ (unsigned char *) &hmac_md5_hash);
/* Copy the hash into the stream */
memcpy (STREAM_DATA (circuit->snd_stream) + auth_tlv_offset + 3,
hmac_md5_hash, ISIS_AUTH_MD5_SIZE);
hmac_md5 (STREAM_DATA (circuit->snd_stream),
stream_get_endp(circuit->snd_stream),
(unsigned char *) &passwd->passwd, passwd->len,
- (caddr_t) &hmac_md5_hash);
+ (unsigned char *) &hmac_md5_hash);
/* Copy the hash into the stream */
memcpy (STREAM_DATA (circuit->snd_stream) + auth_tlv_offset + 3,
hmac_md5_hash, ISIS_AUTH_MD5_SIZE);
hmac_md5 (STREAM_DATA (circuit->snd_stream),
stream_get_endp(circuit->snd_stream),
(unsigned char *) &passwd->passwd, passwd->len,
- (caddr_t) &hmac_md5_hash);
+ (unsigned char *) &hmac_md5_hash);
/* Copy the hash into the stream */
memcpy (STREAM_DATA (circuit->snd_stream) + auth_tlv_offset + 3,
hmac_md5_hash, ISIS_AUTH_MD5_SIZE);
u_char ALL_ISS[6] = { 0x09, 0x00, 0x2B, 0x00, 0x00, 0x05 };
u_char ALL_ESS[6] = { 0x09, 0x00, 0x2B, 0x00, 0x00, 0x04 };
-static char discard_buff[8192];
-static char sock_buff[8192];
+static uint8_t discard_buff[8192];
+static uint8_t sock_buff[8192];
/*
* if level is 0 we are joining p2p multicast
int text_len; /* length of data stream */
unsigned char* key; /* pointer to authentication key */
int key_len; /* length of authentication key */
-caddr_t digest; /* caller digest to be filled in */
+uint8_t* digest; /* caller digest to be filled in */
{
MD5_CTX context;
/* From RFC 2104 */
void hmac_md5(unsigned char* text, int text_len, unsigned char* key,
- int key_len, caddr_t digest);
+ int key_len, uint8_t *digest);
#endif /* ! _LIBZEBRA_MD5_H_*/