Skip to content
This repository was archived by the owner on Feb 13, 2025. It is now read-only.

fix: end a record with \n\r#1

Open
rianby64 wants to merge 1 commit into
emiago:mainfrom
rianby64:main
Open

fix: end a record with \n\r#1
rianby64 wants to merge 1 commit into
emiago:mainfrom
rianby64:main

Conversation

@rianby64
Copy link
Copy Markdown

As per RFC 4566, 5. SDP Specification:

Text fields such as the session name and information are octet
strings that may contain any octet with the exceptions of 0x00 (Nul),
0x0a (ASCII newline), and 0x0d (ASCII carriage return). The sequence
CRLF (0x0d0a) is used to end a record, although parsers SHOULD be
tolerant and also accept records terminated with a single newline
character.

As per RFC 4566, 5. SDP Specification:

   Text fields such as the session name and information are octet
   strings that may contain any octet with the exceptions of 0x00 (Nul),
   0x0a (ASCII newline), and 0x0d (ASCII carriage return).  The sequence
   CRLF (0x0d0a) is used to end a record, although parsers SHOULD be
   tolerant and also accept records terminated with a single newline
   character.
@rianby64
Copy link
Copy Markdown
Author

Hello @emiago !

I posted this pull-request as I'm playing with baresip and I found strange that baresip rejects the call because of the lack of \n\r. I checked in other places and found that the SDP message usually ends with \n\r.

@emiago
Copy link
Copy Markdown
Owner

emiago commented Feb 13, 2025

Hi @rianby64, I guess it is not strict everywhere as Content Lenght also finishes last line.
On other hand I see no issue adding this if it is per RFC.
Have you played with other services?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants