X7ROOT File Manager
Current Path:
/usr/libexec/ipsec
usr
/
libexec
/
ipsec
/
📁
..
📄
_import_crl
(154.26 KB)
📄
_keycensor
(1.38 KB)
📄
_plutorun
(2.98 KB)
📄
_secretcensor
(1.86 KB)
📄
_stackmanager
(14 KB)
📄
_unbound-hook
(1.97 KB)
📄
_updown
(4.23 KB)
📄
_updown.klips
(18.3 KB)
📄
_updown.netkey
(23.31 KB)
📄
addconn
(210.56 KB)
📄
algparse
(345.43 KB)
📄
auto
(5.74 KB)
📄
barf
(11.82 KB)
📄
cavp
(346.02 KB)
📄
enumcheck
(85.1 KB)
📄
eroute
(93.81 KB)
📄
klipsdebug
(69.61 KB)
📄
look
(4.2 KB)
📄
newhostkey
(3.23 KB)
📄
pf_key
(69.18 KB)
📄
pluto
(1.37 MB)
📄
readwriteconf
(182.2 KB)
📄
rsasigkey
(159.04 KB)
📄
setup
(5.58 KB)
📄
show
(3.46 KB)
📄
showhostkey
(159.3 KB)
📄
spi
(346.27 KB)
📄
spigrp
(85.76 KB)
📄
tncfg
(130.14 KB)
📄
verify
(12.04 KB)
📄
whack
(137.93 KB)
Editing: _unbound-hook
#!/usr/bin/python # # Copyright (C) 2018 Paul Wouters <pwouters@redhat.com> # # This program is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by the # Free Software Foundation; either version 2 of the License, or (at your # option) any later version. See <http://www.fsf.org/copyleft/gpl.txt>. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License # for more details. import sys import subprocess # Get my %defaultroute IP address myip = subprocess.check_output("ip -o route get 8.8.8.8", shell=True) myip = myip.split("src")[1].strip().split()[0] argv = sys.argv ourself = argv.pop(0) try: qname = argv.pop(0) ttl = argv.pop(0) ip = argv.pop(0) except: sys.exit("Bad arguments to ipsec _unbound") while (argv != []): try: gwprec = argv.pop(0) gwtype = argv.pop(0) gwalg = argv.pop(0) gwid = argv.pop(0) pubkey = argv.pop(0) addkeyip = "ipsec whack --keyid @%s --addkey --pubkeyrsa 0s%s"%(ip, pubkey) addkeyhostname = "ipsec whack --keyid @%s --addkey --pubkeyrsa 0s%s"%(qname, pubkey) print("processing an IPSECKEY record for Opportunistic IPsec to %s(%s)"%(qname,ip)) print(subprocess.call(addkeyip, shell=True)) print(subprocess.call(addkeyhostname, shell=True)) except: sys.exit("failed to process an IPSECKEY record for Opportunistic IPsec to %s(%s)"%(qname,ip)) # done injecting all IPSECKEY records into pluto - try actual OE now cmdoeip = "ipsec whack --oppohere %s --oppothere %s"%(myip, ip) print(subprocess.check_output(cmdoeip, shell=True)) #cmdoeqname = "ipsec whack --oppohere %s --oppothere %s"%(myip, qname) #ret, output = commands.getstatusoutput(cmdoeqname) print(subprocess.check_output("ipsec whack --trafficstatus", shell=True))
Upload File
Create Folder