Skip to content

Commit

Permalink
- Fix to check length in ATMA string to wire.
Browse files Browse the repository at this point in the history
  • Loading branch information
wcawijngaards committed Jan 21, 2025
1 parent 207ae97 commit 5f58ced
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions doc/Changelog
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
- Fix compile of interface check code when dnscrypt or quic is
disabled.
- Fix encoding of RR type ATMA.
- Fix to check length in ATMA string to wire.

20 January 2025: Yorgos
- Merge #1222: Unique DoT and DoH SSL contexts to allow for different
Expand Down
2 changes: 2 additions & 0 deletions sldns/str2wire.c
Original file line number Diff line number Diff line change
Expand Up @@ -2559,6 +2559,8 @@ int sldns_str2wire_atma_buf(const char* str, uint8_t* rd, size_t* len)

if(slen > LDNS_MAX_RDFLEN*2)
return LDNS_WIREPARSE_ERR_LABEL_OVERFLOW;
if(*len < 1)
return LDNS_WIREPARSE_ERR_BUFFER_TOO_SMALL;
if(*s == 0) {
/* empty string */
rd[0] = 0;
Expand Down

0 comments on commit 5f58ced

Please sign in to comment.