def myfunc():
.....
pr = Process(target=myfunc)
def myfunc_handler(command):
global pr
if .....
def myfunc_handler(COMMAND)
pr=Process(target=myfunc)
if COMMAND == "start" and pr.is_alive==False
pr.start()
.....
......
......
enc = (base64.b64encode(str(pkt).encode('ascii')))
dec = (base64.b64decode(enc).decode('ascii'))
Packet (Length: 90)
Layer ETH:
Destination: c4:6e:1f:07:3f:42
Address: c4:6e:1f:07:3f:42
.... ..0. .... .... .... .... = LG bit: Globally unique address (factory default)
.... ...0 .... .... .... .... = IG bit: Individual address (unicast)
Source: 00:0c:29:ef:ff:9c
Type: IPv4 (0x0800)
Address: 00:0c:29:ef:ff:9c
.... ..0. .... .... .... .... = LG bit: Globally unique address (factory default)
.... ...0 .... .... .... .... = IG bit: Individual address (unicast)
Layer IP:
0100 .... = Version: 4
.... 0101 = Header Length: 20 bytes (5)
Differentiated Services Field: 0x10 (DSCP: Unknown, ECN: Not-ECT)
0001 00.. = Differentiated Services Codepoint: Unknown (4)
.... ..00 = Explicit Congestion Notification: Not ECN-Capable Transport (0)
Total Length: 76
Identification: 0x0e35 (3637)
Flags: 0x4000, Don't fragment
0... .... .... .... = Reserved bit: Not set
.1.. .... .... .... = Don't fragment: Set
..0. .... .... .... = More fragments: Not set
...0 0000 0000 0000 = Fragment offset: 0
Time to live: 64
Protocol: UDP (17)
Header checksum: 0xb187 [validation disabled]
Header checksum status: Unverified
Source: 192.168.0.107
Destination: 91.189.94.4
Layer UDP:
Source Port: 57874
Destination Port: 123
Length: 56
Checksum: 0x7b1e [unverified]
Checksum Status: Unverified
Stream index: 0
Layer NTP:
Flags: 0x23, Leap Indicator: no warning, Version number: NTP Version 4, Mode: client
00.. .... = Leap Indicator: no warning (0)
..10 0... = Version number: NTP Version 4 (4)
.... .011 = Mode: client (3)
Peer Clock Stratum: unspecified or invalid (0)
Peer Polling Interval: invalid (0)
Peer Clock Precision: 1.000000 sec
Root Delay: 0 seconds
Root Dispersion: 0 seconds
Reference ID: NULL
Reference Timestamp: Jan 1, 1970 00:00:00.000000000 UTC
Origin Timestamp: Jan 1, 1970 00:00:00.000000000 UTC
Receive Timestamp: Jan 1, 1970 00:00:00.000000000 UTC
Transmit Timestamp: Feb 21, 2019 21:16:05.190701279 UTC