Commit 88d9991f authored by Pekka Pessi's avatar Pekka Pessi

sip/GRAMMAR: fixed whitespace

darcs-hash:20081127232529-db55f-2f3d2751acabdb6d5c2422707bd91140f083ce2d.gz
parent c1b923eb
/* SIP grammar from RFC3261
*
*
* alphanum = ALPHA / DIGIT
*
*
* reserved = ";" / "/" / "?" / ":" / "@" / "&" / "=" / "+"
* / "$" / ","
* unreserved = alphanum / mark
* mark = "-" / "_" / "." / "!" / "~" / "*" / "'"
* / "(" / ")"
* escaped = "%" HEXDIG HEXDIG
*
*
* LWS = [*WSP CRLF] 1*WSP ; linear whitespace
* SWS = [LWS] ; sep whitespace
*
*
* HCOLON = *( SP / HTAB ) ":" SWS
*
*
* TEXT-UTF8-TRIM = 1*TEXT-UTF8char *(*LWS TEXT-UTF8char)
* TEXT-UTF8char = %x21-7E / UTF8-NONASCII
* UTF8-NONASCII = %xC0-DF 1UTF8-CONT
......@@ -22,9 +22,9 @@
* / %xF8-Fb 4UTF8-CONT
* / %xFC-FD 5UTF8-CONT
* UTF8-CONT = %x80-BF
*
*
* LHEX = DIGIT / %x61-66 ;lowercase a-f
*
*
* token = 1*(alphanum / "-" / "." / "!" / "%" / "*"
* / "_" / "+" / "`" / "'" / "~" )
* separators = "(" / ")" / "<" / ">" / "@" /
......@@ -37,7 +37,7 @@
* ":" / "\" / DQUOTE /
* "/" / "[" / "]" / "?" /
* "{" / "}" )
*
*
* STAR = SWS "*" SWS ; asterisk
* SLASH = SWS "/" SWS ; slash
* EQUAL = SWS "=" SWS ; equal
......@@ -50,18 +50,18 @@
* COLON = SWS ":" SWS ; colon
* LDQUOT = SWS DQUOTE; open double quotation mark
* RDQUOT = DQUOTE SWS ; close double quotation mark
*
*
* comment = LPAREN *(ctext / quoted-pair / comment) RPAREN
* ctext = %x21-27 / %x2A-5B / %x5D-7E / UTF8-NONASCII
* / LWS
*
*
* quoted-string = SWS DQUOTE *(qdtext / quoted-pair ) DQUOTE
* qdtext = LWS / %x21 / %x23-5B / %x5D-7E
* / UTF8-NONASCII
*
*
* quoted-pair = "\" (%x00-09 / %x0B-0C
* / %x0E-7F)
*
*
* SIP-URI = "sip:" [ userinfo ] hostport
* uri-parameters [ headers ]
* SIPS-URI = "sips:" [ userinfo ] hostport
......@@ -84,7 +84,7 @@
* hexseq = hex4 *( ":" hex4)
* hex4 = 1*4HEXDIG
* port = 1*DIGIT
*
*
* uri-parameters = *( ";" uri-parameter)
* uri-parameter = transport-param / user-param / method-param
* / ttl-param / maddr-param / lr-param / other-param
......@@ -103,13 +103,13 @@
* pvalue = 1*paramchar
* paramchar = param-unreserved / unreserved / escaped
* param-unreserved = "[" / "]" / "/" / ":" / "&" / "+" / "$"
*
*
* headers = "?" header *( "&" header )
* header = hname "=" hvalue
* hname = 1*( hnv-unreserved / unreserved / escaped )
* hvalue = *( hnv-unreserved / unreserved / escaped )
* hnv-unreserved = "[" / "]" / "/" / "?" / ":" / "+" / "$"
*
*
* SIP-message = Request / Response
* Request = Request-Line
* *( message-header )
......@@ -137,7 +137,7 @@
* / ";" / ":" / "@" / "&" / "=" / "+" )
* query = *uric
* SIP-Version = "SIP" "/" 1*DIGIT "." 1*DIGIT
*
*
* message-header = (Accept
* / Accept-Encoding
* / Accept-Language
......@@ -183,7 +183,7 @@
* / Warning
* / WWW-Authenticate
* / extension-header) CRLF
*
*
* INVITEm = %x49.4E.56.49.54.45 ; INVITE in caps
* ACKm = %x41.43.4B ; ACK in caps
* OPTIONSm = %x4F.50.54.49.4F.4E.53 ; OPTIONS in caps
......@@ -198,7 +198,7 @@
* *( message-header )
* CRLF
* [ message-body ]
*
*
* Status-Line = SIP-Version SP Status-Code SP Reason-Phrase CRLF
* Status-Code = Informational
* / Redirection
......@@ -210,21 +210,21 @@
* extension-code = 3DIGIT
* Reason-Phrase = *(reserved / unreserved / escaped
* / UTF8-NONASCII / UTF8-CONT / SP / HTAB)
*
*
* Informational = "100" ; Trying
* / "180" ; Ringing
* / "181" ; Call Is Being Forwarded
* / "182" ; Queued
* / "183" ; Session Progress
*
*
* Success = "200" ; OK
*
*
* Redirection = "300" ; Multiple Choices
* / "301" ; Moved Permanently
* / "302" ; Moved Temporarily
* / "305" ; Use Proxy
* / "380" ; Alternative Service
*
*
* Client-Error = "400" ; Bad Request
* / "401" ; Unauthorized
* / "402" ; Payment Required
......@@ -253,7 +253,7 @@
* / "488" ; Not Acceptable Here
* / "491" ; Request Pending
* / "493" ; Undecipherable
*
*
* Server-Error = "500" ; Internal Server Error
* / "501" ; Not Implemented
* / "502" ; Bad Gateway
......@@ -261,12 +261,12 @@
* / "504" ; Server Time-out
* / "505" ; SIP Version not supported
* / "513" ; Message Too Large
*
*
* Global-Failure = "600" ; Busy Everywhere
* / "603" ; Decline
* / "604" ; Does not exist anywhere
* / "606" ; Not Acceptable
*
*
* Accept = "Accept" HCOLON
* [ accept-range *(COMMA accept-range) ]
* accept-range = media-range *(SEMI accept-param)
......@@ -280,23 +280,23 @@
* / ( "1" [ "." 0*3("0") ] )
* generic-param = token [ EQUAL gen-value ]
* gen-value = token / host / quoted-string
*
*
* Accept-Encoding = "Accept-Encoding" HCOLON
* [ encoding *(COMMA encoding) ]
* encoding = codings *(SEMI accept-param)
* codings = content-coding / "*"
* content-coding = token
*
*
* Accept-Language = "Accept-Language" HCOLON
* [ language *(COMMA language) ]
* language = language-range *(SEMI accept-param)
* language-range = ( ( 1*8ALPHA *( "-" 1*8ALPHA ) ) / "*" )
*
*
* Alert-Info = "Alert-Info" HCOLON alert-param *(COMMA alert-param)
* alert-param = LAQUOT absoluteURI RAQUOT *( SEMI generic-param )
*
*
* Allow = "Allow" HCOLON [Method *(COMMA Method)]
*
*
* Authorization = "Authorization" HCOLON credentials
* credentials = ("Digest" LWS digest-response)
* / other-response
......@@ -323,7 +323,7 @@
* other-response = auth-scheme LWS auth-param
* *(COMMA auth-param)
* auth-scheme = token
*
*
* Authentication-Info = "Authentication-Info" HCOLON ainfo
* *(COMMA ainfo)
* ainfo = nextnonce / message-qop
......@@ -332,29 +332,29 @@
* nextnonce = "nextnonce" EQUAL nonce-value
* response-auth = "rspauth" EQUAL response-digest
* response-digest = LDQUOT *LHEX RDQUOT
*
*
* Call-ID = ( "Call-ID" / "i" ) HCOLON callid
* callid = word [ "@" word ]
*
*
* Call-Info = "Call-Info" HCOLON info *(COMMA info)
* info = LAQUOT absoluteURI RAQUOT *( SEMI info-param)
* info-param = ( "purpose" EQUAL ( "icon" / "info"
* / "card" / token ) ) / generic-param
*
*
* Contact = ("Contact" / "m" ) HCOLON
* ( STAR / (contact-param *(COMMA contact-param)))
* contact-param = (name-addr / addr-spec) *(SEMI contact-params)
* name-addr = [ display-name ] LAQUOT addr-spec RAQUOT
* addr-spec = SIP-URI / SIPS-URI / absoluteURI
* display-name = *(token LWS)/ quoted-string
*
*
* contact-params = c-p-q / c-p-expires
* / contact-extension
* c-p-q = "q" EQUAL qvalue
* c-p-expires = "expires" EQUAL delta-seconds
* contact-extension = generic-param
* delta-seconds = 1*DIGIT
*
*
* Content-Disposition = "Content-Disposition" HCOLON
* disp-type *( SEMI disp-param )
* disp-type = "render" / "session" / "icon" / "alert"
......@@ -365,16 +365,16 @@
* / other-handling )
* other-handling = token
* disp-extension-token = token
*
*
* Content-Encoding = ( "Content-Encoding" / "e" ) HCOLON
* content-coding *(COMMA content-coding)
*
*
* Content-Language = "Content-Language" HCOLON
* language-tag *(COMMA language-tag)
* language-tag = primary-tag *( "-" subtag )
* primary-tag = 1*8ALPHA
* subtag = 1*8ALPHA
*
*
* Content-Length = ( "Content-Length" / "l" ) HCOLON 1*DIGIT
* Content-Type = ( "Content-Type" / "c" ) HCOLON media-type
* media-type = m-type SLASH m-subtype *(SEMI m-parameter)
......@@ -390,9 +390,9 @@
* m-parameter = m-attribute EQUAL m-value
* m-attribute = token
* m-value = token / quoted-string
*
*
* CSeq = "CSeq" HCOLON 1*DIGIT LWS Method
*
*
* Date = "Date" HCOLON SIP-date
* SIP-date = rfc1123-date
* rfc1123-date = wkday "," SP date1 SP time SP "GMT"
......@@ -405,32 +405,32 @@
* month = "Jan" / "Feb" / "Mar" / "Apr"
* / "May" / "Jun" / "Jul" / "Aug"
* / "Sep" / "Oct" / "Nov" / "Dec"
*
*
* Error-Info = "Error-Info" HCOLON error-uri *(COMMA error-uri)
* error-uri = LAQUOT absoluteURI RAQUOT *( SEMI generic-param )
*
*
* Expires = "Expires" HCOLON delta-seconds
* From = ( "From" / "f" ) HCOLON from-spec
* from-spec = ( name-addr / addr-spec )
* *( SEMI from-param )
* from-param = tag-param / generic-param
* tag-param = "tag" EQUAL token
*
*
* In-Reply-To = "In-Reply-To" HCOLON callid *(COMMA callid)
*
*
* Max-Forwards = "Max-Forwards" HCOLON 1*DIGIT
*
*
* MIME-Version = "MIME-Version" HCOLON 1*DIGIT "." 1*DIGIT
*
*
* Min-Expires = "Min-Expires" HCOLON delta-seconds
*
*
* Organization = "Organization" HCOLON [TEXT-UTF8-TRIM]
*
*
* Priority = "Priority" HCOLON priority-value
* priority-value = "emergency" / "urgent" / "normal"
* / "non-urgent" / other-priority
* other-priority = token
*
*
* Proxy-Authenticate = "Proxy-Authenticate" HCOLON challenge
* challenge = ("Digest" LWS digest-cln *(COMMA digest-cln))
* / other-challenge
......@@ -453,53 +453,53 @@
* qop-options = "qop" EQUAL LDQUOT qop-value
* *("," qop-value) RDQUOT
* qop-value = "auth" / "auth-int" / token
*
*
* Proxy-Authorization = "Proxy-Authorization" HCOLON credentials
*
*
* Proxy-Require = "Proxy-Require" HCOLON option-tag
* *(COMMA option-tag)
* option-tag = token
*
*
* Record-Route = "Record-Route" HCOLON rec-route *(COMMA rec-route)
* rec-route = name-addr *( SEMI rr-param )
* rr-param = generic-param
*
*
* Reply-To = "Reply-To" HCOLON rplyto-spec
* rplyto-spec = ( name-addr / addr-spec )
* *( SEMI rplyto-param )
* rplyto-param = generic-param
* Require = "Require" HCOLON option-tag *(COMMA option-tag)
*
*
* Retry-After = "Retry-After" HCOLON delta-seconds
* [ comment ] *( SEMI retry-param )
*
*
* retry-param = ("duration" EQUAL delta-seconds)
* / generic-param
*
*
* Route = "Route" HCOLON route-param *(COMMA route-param)
* route-param = name-addr *( SEMI rr-param )
*
*
* Server = "Server" HCOLON server-val *(LWS server-val)
* server-val = product / comment
* product = token [SLASH product-version]
* product-version = token
*
*
* Subject = ( "Subject" / "s" ) HCOLON [TEXT-UTF8-TRIM]
*
*
* Supported = ( "Supported" / "k" ) HCOLON
* [option-tag *(COMMA option-tag)]
*
*
* Timestamp = "Timestamp" HCOLON 1*(DIGIT)
* [ "." *(DIGIT) ] [ LWS delay ]
* delay = *(DIGIT) [ "." *(DIGIT) ]
*
*
* To = ( "To" / "t" ) HCOLON ( name-addr
* / addr-spec ) *( SEMI to-param )
* to-param = tag-param / generic-param
*
*
* Unsupported = "Unsupported" HCOLON option-tag *(COMMA option-tag)
* User-Agent = "User-Agent" HCOLON server-val *(LWS server-val)
*
*
* Via = ( "Via" / "v" ) HCOLON via-parm *(COMMA via-parm)
* via-parm = sent-protocol LWS sent-by *( SEMI via-params )
* via-params = via-ttl / via-maddr
......@@ -518,7 +518,7 @@
* / other-transport
* sent-by = host [ COLON port ]
* ttl = 1*3DIGIT ; 0 to 255
*
*
* Warning = "Warning" HCOLON warning-value *(COMMA warning-value)
* warning-value = warn-code SP warn-agent SP warn-text
* warn-code = 3DIGIT
......@@ -527,9 +527,9 @@
* ; the Warning header, for use in debugging
* warn-text = quoted-string
* pseudonym = token
*
*
* WWW-Authenticate = "WWW-Authenticate" HCOLON challenge
*
*
* extension-header = header-name HCOLON header-value
* header-name = token
* header-value = *(TEXT-UTF8char / UTF8-CONT / LWS)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment