This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
export PATH="/bin:/sbin:/usr/sbin:/usr/bin" | |
OLDGW=`ip route show | grep '^default via' | grep ' metric 1' | sed -e 's/default via \([^ ]*\).*/\1/' | uniq ` | |
#if [ $OLDGW == '' ]; then | |
# exit 0 | |
#fi | |
#if [ ! -e /tmp/vpn_oldgw ]; then | |
# echo $OLDGW > /tmp/vpn_oldgw |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
while true : | |
do | |
tmuxPID=$(ps w | grep tmux | grep download | grep -v grep | awk '{print $1}') | |
[ -z "$tmuxPID" ] && tmux new -d -s download 'python /bin/lx download --watch --category=video --node=fast --node-detection-acceptable=1M' | |
sleep 60; | |
done |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[email protected] | |
--aria2-opts=-s10 -x10 -c | |
--node-detection-acceptable=1M | |
--no-hash | |
--output-dir=/movies | |
--completed | |
--encoding=utf-8 | |
--node=fast | |
--colors | |
--continue |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
reaverCMD() | |
{ | |
reaver -i mon0 -b $1 -v -a -S -N -r 100:60 $2 >>/var/log/reaver.pin.log & | |
tmp_pid=$(ps a| grep reaver | grep -v grep | awk '{print $1}' ); | |
echo $tmp_pid; | |
} | |
while true : | |
do |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
#set -x | |
start () | |
{ | |
airmon-ng check kill; | |
ifdown $1; | |
iwconfig $1 mode mon; | |
ifup $1; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
begin remote | |
name MiniHongWai | |
# header 8926 4487 | |
# one 542 1689 | |
# zero 542 576 | |
# ptrail 549 | |
# repeat 8928 2242 | |
# gap 107255 | |
# min_repeat 2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
root@v2:~# cat /etc/asterisk/sip.conf | |
;================================= | |
; SIP Configuration for Asterisk | |
; | |
[general] | |
context=sip ;默认使用extension.conf中的sip字段 | |
videosupport=yes ;打开视频支持,有些客户端(手机)支持视频 | |
textsupport = yes ;短信支持 | |
ccept_outofcall_message = yes | |
outofcall_message_context = messages |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
root@v2:~# cat /etc/asterisk/extensions.conf | |
;================================== | |
; extensions.conf - the Asterisk dial plan | |
; | |
[general] | |
static=no | |
writeprotect=no | |
autofallthrough=yes | |
clearglobalvars=no | |
priorityjumping=no |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NO_MODULES=yes | |
NO_KERNELDEPEND=yes | |
NO_KERNELOBJ=yes |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/sh | |
#! /usr/bin/expect -f | |
certtool --generate-privkey --outfile $1-key.pem | |
sed -i "1ccn = "${1}"" client.tmpl | |
sed -i "3cemail = ${1}@abc.org" client.tmpl | |
certtool --generate-certificate --load-privkey $1-key.pem --load-ca-certificate ca-cert.pem --load-ca-privkey ca-key.pem --template client.tmpl --outfile $1-cert.pem | |
openssl pkcs12 -export -inkey $1-key.pem -in $1-cert.pem -name "$1 VPN Client Cert" -certfile ca-cert.pem -out $1.cert.p12 |
OlderNewer