From c6068befe92b8a57c14895fce91c3f9f484112ae Mon Sep 17 00:00:00 2001 From: delphij Date: Wed, 27 Jan 2016 07:41:31 +0000 Subject: Fix multiple vulnerabilities of ntp. [SA-16:09] Fix Linux compatibility layer issetugid(2) system call vulnerability. [SA-16:10] Security: FreeBSD-SA-16:09.ntp Security: FreeBSD-SA-16:10.linux Approved by: so --- contrib/ntp/sntp/crypto.h | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) (limited to 'contrib/ntp/sntp/crypto.h') diff --git a/contrib/ntp/sntp/crypto.h b/contrib/ntp/sntp/crypto.h index 39e0e6b..19cdbc4 100644 --- a/contrib/ntp/sntp/crypto.h +++ b/contrib/ntp/sntp/crypto.h @@ -17,16 +17,18 @@ /* #include "sntp-opts.h" */ struct key { - struct key *next; - int key_id; - int key_len; - char type[10]; - char key_seq[64]; + struct key * next; + int key_id; + int key_len; + char type[10]; + char key_seq[64]; }; -int auth_init(const char *keyfile, struct key **keys); -void get_key(int key_id, struct key **d_key); -int make_mac(char *pkt_data, int pkt_size, int mac_size, struct key *cmp_key, char *digest); -int auth_md5(char *pkt_data, int pkt_size, int mac_size, struct key *cmp_key); +extern int auth_init(const char *keyfile, struct key **keys); +extern void get_key(int key_id, struct key **d_key); +extern int make_mac(const void *pkt_data, int pkt_size, int mac_size, + const struct key *cmp_key, void *digest); +extern int auth_md5(const void *pkt_data, int pkt_size, int mac_size, + const struct key *cmp_key); #endif -- cgit v1.1