Changeset 1403:6a35c5470ef4 in freeDiameter for libfdproto
- Timestamp:
- Jul 7, 2020, 2:24:48 AM (4 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
libfdproto/messages.c
r1327 r1403 1947 1947 } 1948 1948 1949 /* Check the length is valid */ 1950 if ( avp->avp_public.avp_len < GETAVPHDRSZ(avp->avp_public.avp_flags) ) { 1951 TRACE_DEBUG(INFO, "Invalid AVP size %d", 1952 avp->avp_public.avp_len); 1953 free(avp); 1954 return EBADMSG; 1955 } 1956 1949 1957 /* Check there is enough remaining data in the buffer */ 1950 1958 if ( (avp->avp_public.avp_len > GETAVPHDRSZ(avp->avp_public.avp_flags)) … … 1992 2000 TRACE_DEBUG(INFO, "Truncated message (%zd / %d)", buflen, msglen ); 1993 2001 return EBADMSG; 2002 } 2003 if ( msglen < GETMSGHDRSZ() ) { 2004 TRACE_DEBUG(INFO, "Invalid message length (%d)", msglen ); 2005 return EBADMSG; 1994 2006 } 1995 2007
Note: See TracChangeset
for help on using the changeset viewer.