summaryrefslogtreecommitdiffstats
path: root/scripts/external_libs/dpkt-1.8.6/dpkt/sip.py
diff options
context:
space:
mode:
authorDan Klein <danklei@csi-kiwi-03.cisco.com>2015-09-20 15:53:42 +0300
committerDan Klein <danklei@csi-kiwi-03.cisco.com>2015-09-20 15:53:42 +0300
commit28fef018f75b5a54ac69ac7c919127bf47f5b61f (patch)
treec21c2af8dfe7c05bee170e96fc923458b8894be6 /scripts/external_libs/dpkt-1.8.6/dpkt/sip.py
parenta78680a896f65dd6733d27d99e9cd8440eb185e9 (diff)
parent56dbd342eb97fc087611157ce8e965088b7f9bf8 (diff)
Pushed Stateless progress (along with Packet Builder module)
Diffstat (limited to 'scripts/external_libs/dpkt-1.8.6/dpkt/sip.py')
-rw-r--r--scripts/external_libs/dpkt-1.8.6/dpkt/sip.py32
1 files changed, 32 insertions, 0 deletions
diff --git a/scripts/external_libs/dpkt-1.8.6/dpkt/sip.py b/scripts/external_libs/dpkt-1.8.6/dpkt/sip.py
new file mode 100644
index 00000000..398eab8a
--- /dev/null
+++ b/scripts/external_libs/dpkt-1.8.6/dpkt/sip.py
@@ -0,0 +1,32 @@
+# $Id: sip.py 48 2008-05-27 17:31:15Z yardley $
+
+"""Session Initiation Protocol."""
+
+import http
+
+class Request(http.Request):
+ """SIP request."""
+ __hdr_defaults__ = {
+ 'method':'INVITE',
+ 'uri':'sip:user@example.com',
+ 'version':'2.0',
+ 'headers':{ 'To':'', 'From':'', 'Call-ID':'', 'CSeq':'', 'Contact':'' }
+ }
+ __methods = dict.fromkeys((
+ 'ACK', 'BYE', 'CANCEL', 'INFO', 'INVITE', 'MESSAGE', 'NOTIFY',
+ 'OPTIONS', 'PRACK', 'PUBLISH', 'REFER', 'REGISTER', 'SUBSCRIBE',
+ 'UPDATE'
+ ))
+ __proto = 'SIP'
+
+class Response(http.Response):
+ """SIP response."""
+ __hdr_defaults__ = {
+ 'version':'2.0',
+ 'status':'200',
+ 'reason':'OK',
+ 'headers':{ 'To':'', 'From':'', 'Call-ID':'', 'CSeq':'', 'Contact':'' }
+ }
+ __proto = 'SIP'
+
+