-
Notifications
You must be signed in to change notification settings - Fork 5
/
gremlina.py
41 lines (38 loc) · 1.79 KB
/
gremlina.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
"""########################################################
########################################################
#
# GREMLIN: the GRASP daemon
#
# This module is for use in a node that can relay GRASP
# but is not running any ASA. This version needs no initial
# dialogue with the user.
#
# Because it's demonstration code written in an
# interpreted language, performance is slow.
#
# SECURITY WARNINGS:
# - assumes ACP up on all interfaces (or none)
# - assumes BUT DOES NOT CHECK that layer 2 is secured
# - does not watch for interface up/down changes
# (but does handle IPv6 address changes)
# - use of QUADS security is highly recommended
#
# LIMITATIONS:
# - only coded for IPv6, any IPv4 is accidental
# - survival of address changes and CPU sleep/wakeup is patchy
# - workarounds for defects in Python socket module and
# Windows socket peculiarities. Not tested on Android.
#
# See grasp.py for license, copyright, and disclaimer.
#
########################################################
########################################################"""
import grasp
import time
print("Starting GRASP daemon without dialogue")
grasp.skip_dialogue(testing=False, selfing=True, diagnosing=False)
grasp._initialise_grasp()
grasp.init_bubble_text("GRASP daemon")
grasp.tprint("Daemon running")
while True:
time.sleep(60)