forked from I2P_Developers/i2p.i2p
initial import of Connelly's public domain I2P python lib
This commit is contained in:
13
apps/sam/python/src/examples/raw_server.py
Normal file
13
apps/sam/python/src/examples/raw_server.py
Normal file
@@ -0,0 +1,13 @@
|
||||
|
||||
# -----------------------------------------------
|
||||
# raw_server.py: Raw server
|
||||
# -----------------------------------------------
|
||||
|
||||
from i2p import sam
|
||||
|
||||
S = sam.socket('Eve', sam.SOCK_RAW)
|
||||
print 'Serving at:', S.dest
|
||||
|
||||
while True:
|
||||
data = S.recv(1000) # Read packet
|
||||
print 'Got', data
|
||||
Reference in New Issue
Block a user