[SIPForum-discussion] A CRLF for multi-line?

Herve Jourdain herve.jourdain at mstarsemi.com
Sat Dec 22 12:10:15 UTC 2007



1.	I think you can get the information in the RFC 3261, in the
“Augmented BNF” part (chapter 25, p.219)
A line can be continued on another line if this other line starts with a
“space” (SP), a “Horizontal Tab” (HTAB) or a “Linear White Space”
Depending on your parsing strategy and implementation, you could preprocess
the SIP message and replace any LWS you find by a single SP… Or you can add
your parsing rules taking LWS into account.
So to answer to your question, the end character for the first line is CRLF,
SIP considers it’s folded with the NEXT LINE starting with a WSP…
In fact, I guess every “line” in SIP ends with a CRLF.
2.	As Far As I Know, the “multi-line” process is completely
orthogonal with the syntax, so you should just be able to split anywhere in
the SIP message.








From: discussion-bounces at sipforum.org
[mailto:discussion-bounces at sipforum.org] On Behalf Of ? ?
Sent: vendredi 21 décembre 2007 14:08
To: discussion at sipforum.org
Subject: [SIPForum-discussion] A CRLF for multi-line?


Hi, all

Through I have tried my best, there are two things puzzle me:
1.If a SIP header field values be folded onto multiple lines.
          From: Bob <sip:bob at biloxi.com>;tag=a6c8 <CRLF>  
*=>  From: Bob <sip:bob at biloxi.com> <??>
          *<SP>;tag=a6c8 <CRLF>  
  Well, the RFC3261 states the extended line should have at least a SP or
TAB as beginner character, but how about the end of the first line , Is
there still a CRLF?                                 


2.Is any header field could be split into a multiple line or just some
particular fields can do this ? 


As I am doing the SIP parsing now, your answer is very important to me!








e> 雅虎邮箱传递新年祝福,个性贺卡送亲朋! 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://sipforum.org/pipermail/discussion/attachments/20071222/96d7a401/attachment-0014.html>

More information about the discussion mailing list