Server location:Frankfurt,German
Server ip:5.231.34.154
Server port:8883
Password:whoisyourbitch
Method:AES-256-CFB
Valid date until August 1st 2015
2015年7月29日星期三
2015年4月22日星期三
讓mediatomb支持中文及各國語言
mediatomb為linux中較為出色的uPnP/DLNA server,很可惜其中的中文文件名往往顯示為亂碼或空格,這裡有辦法讓mediatomb顯示中文。
以下命令行皆為root用戶。
1.修改config.xml文件:
nano /etc/mediatomb/config.xml
在<scripting script-charset="UTF-8">之前加入以下兩段代碼:
<filesystem-charset>UTF-8</filesystem-charset>
<metadata-charset>UTF-8</metadata-charset>
保存退出。
2.重建db
rm /var/lib/mediatomb/mediatomb.db
注:如mediatomb為初始安裝則無db,跳過此步驟即可。
3.重啟mediatomb
/etc/init.d/mediatomb restart
用局域網任一電腦中的firefox打開http://serverip:49152 (serverip替換為你自己的mediatomb server ip),現在添加中文名的mp3或者視頻則可正常顯示了
以下命令行皆為root用戶。
1.修改config.xml文件:
nano /etc/mediatomb/config.xml
在<scripting script-charset="UTF-8">之前加入以下兩段代碼:
<filesystem-charset>UTF-8</filesystem-charset>
<metadata-charset>UTF-8</metadata-charset>
保存退出。
2.重建db
rm /var/lib/mediatomb/mediatomb.db
注:如mediatomb為初始安裝則無db,跳過此步驟即可。
3.重啟mediatomb
/etc/init.d/mediatomb restart
用局域網任一電腦中的firefox打開http://serverip:49152 (serverip替換為你自己的mediatomb server ip),現在添加中文名的mp3或者視頻則可正常顯示了
2015年3月29日星期日
Install xfce and vncserver on Debian
1.Using putty log in to Debian vps.
2.apt-get update
3.apt-get install xorg
4.apt-get install xfce4
5.apt-get install vnc4server
6.apt-get install iceweasel -y
7.start vncserver with commander:
vncserver
Type password you're going to use twice.
8.kill vncserver with commander:
vncserver -kill :1
9.nano /root/.vnc/xstartup
This file must be looked like this:
#!bin/sh
/usr/bin/startxfce4 &
10.restart vncserver with commander:
vncserver
11.log in to vnc using tightvncviewer with serverip:5901 and type your password you've set in step 7.
Done.
2.apt-get update
3.apt-get install xorg
4.apt-get install xfce4
5.apt-get install vnc4server
6.apt-get install iceweasel -y
7.start vncserver with commander:
vncserver
Type password you're going to use twice.
8.kill vncserver with commander:
vncserver -kill :1
9.nano /root/.vnc/xstartup
This file must be looked like this:
#!bin/sh
/usr/bin/startxfce4 &
10.restart vncserver with commander:
vncserver
11.log in to vnc using tightvncviewer with serverip:5901 and type your password you've set in step 7.
Done.
2015年3月22日星期日
Free shadowsocks service from L.A.
8月21日,加密方式已變更為aes-256-cfb.(Method has changed to aes-256-cfb)
警告:如使用BT,Emule,迅雷等P2P下載軟件或者發送垃圾郵件造成VPS被封,本人絕對不會去與ISP協商取回,請各自珍惜。
Warning: P2P downloading and sending spam are forbidden.
Free shadowsocks details:
Server ip:167.160.165.189
Server port:8883
Password: whoisyourbitch
Method:table
Method:aes-256-cfb
注意:本VPS有效期直到2015年10月,如無法連接則是有人使用P2P造成VPS被封,也不要詢問本人如何使用客戶端連接,請自行Google.
警告:如使用BT,Emule,迅雷等P2P下載軟件或者發送垃圾郵件造成VPS被封,本人絕對不會去與ISP協商取回,請各自珍惜。
Warning: P2P downloading and sending spam are forbidden.
Free shadowsocks details:
Server ip:167.160.165.189
Server port:8883
Password: whoisyourbitch
Method:aes-256-cfb
注意:本VPS有效期直到2015年10月,如無法連接則是有人使用P2P造成VPS被封,也不要詢問本人如何使用客戶端連接,請自行Google.
2015年2月12日星期四
Debian VPS (OPENVZ)安裝pptp vpn
Debian vps可按如下進度安裝pptp vpn:
1.使用putty登錄vps,通常是root賬戶,登錄成功後輸入以下命令查驗vps是否已開啟ppp:
cat /dev/ppp
如果返回以下結果則ppp已開啟:
cat /dev/ppp: No such device or address
如果不是請詢問你的vps供應商
2.安裝pptpd,命令如下
apt-get update
apt-get install pptpd
(以上安裝命令只適用於Debian或Ubuntu及其衍生版,如果是其他linux發行版請自行google.)
3.配置pptpd和ppp,首先修改pptpd.conf
nano /etc/pptpd.conf
(這裡的文本編輯器不一定要用nano,可以用已安裝的或者最喜歡的,比如vi,vim等)
將以下兩行加到文件的最後面,已有這兩行的把最前面的#去掉即可:
localip 10.10.0.1
remoteip 10.10.0.2-100
保存退出。
這裡的localip和remoteip不一定要使用這個,也可以定義為192.168.x.y。只要不與本地ip重疊即可。
到這裡還沒完,繼續修改pptpd-options,我用的文本編輯器依然是nano,命令如下:
nano /etc/pptpd-options
打開後將如下幾行copy或者加入到文件最後,保存退出:
name pptpd
refuse-pap
refuse-chap
refuse-mschap
require-mschap-v2
require-mppe-128
ms-dns 8.8.8.8
#ms-dns 8.8.4.4
proxyarp
nodefaultroute
lock
nobsdcomp
mtu 1490
mru 1490
4.添加pptpd賬戶和密碼,使用文本編輯器打開/etc/ppp/chap-secrets添加用戶名和密碼,每行一個用戶,比如:
user1 <tab> pptpd <tab> password1 <tab> 10.10.0.2
user2 <tab> pptpd <tab> password2 <tab> 10.10.0.3
user3 <tab> pptpd <tab> password3 <tab> 10.10.0.4
user4 <tab> pptpd <tab> password4 <tab> 10.10.0.5
這裡的user1,password1等內容是你自己設定的pptpd登錄賬號的用戶名和密碼,你可以自己修改,pptpd是固定的,後面的ip是remoteip,與上面自己設定的remoteip段保持一致。<tab>指兩個參加值之間用一個tab鍵隔開,而不是讓你輸入tab三個字母
5.啟用數據轉發,打開sysctl.conf:
nano /etc/sysctl.conf
將下列一行添加或者將已有的#去掉:
net.ipv4.ip_forward=1
保存退出
運行以下命令使修改生效:
sysctl -p
6.添加iptables規則:
iptables -t nat -A POSTROUTING -j SNAT --to-source <Public Server IP>
<Public Server IP>換成你自己的服務器ip,以上規則僅適用於openvz,如果是kvm或xen,規則如下:
iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
iptables -A FORWARD -i eth0 -o ppp0 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i ppp0 -o eth0 -j ACCEPT
7.重啟pptpd:
service pptpd restart
至此你可以在電腦和手機裡輸入你的賬號密碼和服務器ip鏈接到pptp vpn.
如有問題,請在google+,twitter上聯絡我。
清除NAT規則:
iptables --table nat --flush
1.使用putty登錄vps,通常是root賬戶,登錄成功後輸入以下命令查驗vps是否已開啟ppp:
cat /dev/ppp
如果返回以下結果則ppp已開啟:
cat /dev/ppp: No such device or address
如果不是請詢問你的vps供應商
2.安裝pptpd,命令如下
apt-get update
apt-get install pptpd
(以上安裝命令只適用於Debian或Ubuntu及其衍生版,如果是其他linux發行版請自行google.)
3.配置pptpd和ppp,首先修改pptpd.conf
nano /etc/pptpd.conf
(這裡的文本編輯器不一定要用nano,可以用已安裝的或者最喜歡的,比如vi,vim等)
將以下兩行加到文件的最後面,已有這兩行的把最前面的#去掉即可:
localip 10.10.0.1
remoteip 10.10.0.2-100
保存退出。
這裡的localip和remoteip不一定要使用這個,也可以定義為192.168.x.y。只要不與本地ip重疊即可。
到這裡還沒完,繼續修改pptpd-options,我用的文本編輯器依然是nano,命令如下:
nano /etc/pptpd-options
打開後將如下幾行copy或者加入到文件最後,保存退出:
name pptpd
refuse-pap
refuse-chap
refuse-mschap
require-mschap-v2
require-mppe-128
ms-dns 8.8.8.8
#ms-dns 8.8.4.4
proxyarp
nodefaultroute
lock
nobsdcomp
mtu 1490
mru 1490
4.添加pptpd賬戶和密碼,使用文本編輯器打開/etc/ppp/chap-secrets添加用戶名和密碼,每行一個用戶,比如:
user1 <tab> pptpd <tab> password1 <tab> 10.10.0.2
user2 <tab> pptpd <tab> password2 <tab> 10.10.0.3
user3 <tab> pptpd <tab> password3 <tab> 10.10.0.4
user4 <tab> pptpd <tab> password4 <tab> 10.10.0.5
這裡的user1,password1等內容是你自己設定的pptpd登錄賬號的用戶名和密碼,你可以自己修改,pptpd是固定的,後面的ip是remoteip,與上面自己設定的remoteip段保持一致。<tab>指兩個參加值之間用一個tab鍵隔開,而不是讓你輸入tab三個字母
5.啟用數據轉發,打開sysctl.conf:
nano /etc/sysctl.conf
將下列一行添加或者將已有的#去掉:
net.ipv4.ip_forward=1
保存退出
運行以下命令使修改生效:
sysctl -p
6.添加iptables規則:
iptables -t nat -A POSTROUTING -j SNAT --to-source <Public Server IP>
<Public Server IP>換成你自己的服務器ip,以上規則僅適用於openvz,如果是kvm或xen,規則如下:
iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
iptables -A FORWARD -i eth0 -o ppp0 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i ppp0 -o eth0 -j ACCEPT
7.重啟pptpd:
service pptpd restart
至此你可以在電腦和手機裡輸入你的賬號密碼和服務器ip鏈接到pptp vpn.
如有問題,請在google+,twitter上聯絡我。
清除NAT規則:
iptables --table nat --flush
2015年1月31日星期六
翻牆利器Shadowsocks的安裝與配置
最近中國大陸的網絡封鎖越來越嚴重,這裡寫個Shadowsocks教程共享給中國大陸的朋友。
以下方法在Debian VPS上實踐過,很好用。
工具:Putty (可到putty.org官網下載putty.exe單文件免安裝版)
服務器端:Debian 7
客戶端系統:Windows 8 pro ZH-HK x86
客戶端:Shadowsocks Gui (可到sourceforge下載http://sourceforge.net/projects/shadowsocksgui/files/latest/download)
備好這些軟件工具後,就可以安裝了。
1.首先使用putty輸入你的VPS ip地址登錄到你的Vps,鏈接上以後輸入用戶名(一般為root)和密碼。
2.只需兩行命令即可安裝好shadowsocks服務器端。
apt-get install python-pip
pip install shadowsocks
3.配置服務器端
cd /etc
mkdir shadowsocks
cd shadowsocks
nano config.json
將以後配置copy到config.json,其中的密碼password改為你自己想設定的密碼,端口也可修改,另外加密方式table比aes-256-cfb速度快些,但極不安全,推薦使用aes-256-cfb,其他請不要隨便修改。
config.json樣例:
{
"server":"0.0.0.0",
"server_port":8388,
"local_address":"127.0.0.1",
"local_port":8388,
"password":"changetoyourpassword",
"timeout":400,
"method":"aes-256-cfb",
"fast_open":false,
"workers":1
}
複製修改上面的配置文件到config.json上用CTRL+X退出時會問你是否保存選Y。
4.客戶端配置
打開Shadowsocks Gui添加服務器,服務器ip寫你vps的IP地址,服務器端口與上面config.json的server_port保持一致就是8388, 密碼填上面的password就是changetoyourpassword,備註可以不填,保存退出,然後勾選啟用系統代理,默認為pac模式,IE瀏覽器會自動調用,不用另外修改IE的代理。
5.測試運行
在putty裡運行shadowsocks服務器端,輸入命令
ssserver
回車後會提示你shadowsocks正在運行。
此刻別急著關閉putty。
打開IE瀏覽器,輸入網址www.youtube.com看是否能打開,同時可以觀察putty裡shadowsocks是否正在執行。如果能打開證明配置成功。此時可以使用CTRL+C終止shadowsocks server.
3.服務器 後台運行
可以使用以下命令後台運行shaodwsocks服務器端:
nohup ssserver > log &
如果沒有返回到root@server:~#可使用CTRL+C終止,然後輸入以下命令即可後台運行:
nohup ssserver > log
另外,shadowsocks在github上的頁面也有介紹其他可以後台執行的辦法,本辦法來源於Archlinux。
還有一個問題,大家有可能覺得購買vps也可開銷,而且速度也並不比Goagent快,但面對Google被封,經常查不到可用的google ip,自己購買vps可以作為備用,費用也不高,甚至洛杉磯機房有10美元一年的vps.在這裡推薦一家名為crissic 。可購買其LOS ANGELES OPENVZ OVZ256,進10美元/年,千萬別選JACKSONVILLE節點,ping值會多65ms左右,速度會慢一些。網址:https://crissic.net
以下方法在Debian VPS上實踐過,很好用。
工具:Putty (可到putty.org官網下載putty.exe單文件免安裝版)
服務器端:Debian 7
客戶端系統:Windows 8 pro ZH-HK x86
客戶端:Shadowsocks Gui (可到sourceforge下載http://sourceforge.net/projects/shadowsocksgui/files/latest/download)
備好這些軟件工具後,就可以安裝了。
1.首先使用putty輸入你的VPS ip地址登錄到你的Vps,鏈接上以後輸入用戶名(一般為root)和密碼。
2.只需兩行命令即可安裝好shadowsocks服務器端。
apt-get install python-pip
pip install shadowsocks
3.配置服務器端
cd /etc
mkdir shadowsocks
cd shadowsocks
nano config.json
將以後配置copy到config.json,其中的密碼password改為你自己想設定的密碼,端口也可修改,另外加密方式table比aes-256-cfb速度快些,但極不安全,推薦使用aes-256-cfb,其他請不要隨便修改。
config.json樣例:
{
"server":"0.0.0.0",
"server_port":8388,
"local_address":"127.0.0.1",
"local_port":8388,
"password":"changetoyourpassword",
"timeout":400,
"method":"aes-256-cfb",
"fast_open":false,
"workers":1
}
複製修改上面的配置文件到config.json上用CTRL+X退出時會問你是否保存選Y。
4.客戶端配置
打開Shadowsocks Gui添加服務器,服務器ip寫你vps的IP地址,服務器端口與上面config.json的server_port保持一致就是8388, 密碼填上面的password就是changetoyourpassword,備註可以不填,保存退出,然後勾選啟用系統代理,默認為pac模式,IE瀏覽器會自動調用,不用另外修改IE的代理。
5.測試運行
在putty裡運行shadowsocks服務器端,輸入命令
ssserver
回車後會提示你shadowsocks正在運行。
此刻別急著關閉putty。
打開IE瀏覽器,輸入網址www.youtube.com看是否能打開,同時可以觀察putty裡shadowsocks是否正在執行。如果能打開證明配置成功。此時可以使用CTRL+C終止shadowsocks server.
3.服務器 後台運行
可以使用以下命令後台運行shaodwsocks服務器端:
nohup ssserver > log &
如果沒有返回到root@server:~#可使用CTRL+C終止,然後輸入以下命令即可後台運行:
nohup ssserver > log
另外,shadowsocks在github上的頁面也有介紹其他可以後台執行的辦法,本辦法來源於Archlinux。
還有一個問題,大家有可能覺得購買vps也可開銷,而且速度也並不比Goagent快,但面對Google被封,經常查不到可用的google ip,自己購買vps可以作為備用,費用也不高,甚至洛杉磯機房有10美元一年的vps.在這裡推薦一家名為crissic 。可購買其LOS ANGELES OPENVZ OVZ256,進10美元/年,千萬別選JACKSONVILLE節點,ping值會多65ms左右,速度會慢一些。網址:https://crissic.net
2014年3月27日星期四
Attackers get cash out of ATMs by sending SMS messages
Criminals are using SMS messages to get cash out of ATMs, according to Symantec.
The crooks begin by loading ATM malware into the cash machine. In the Monday post, Symantec used Ploutus, a piece of malware observed circulating Mexico in October 2013 that was later discovered to have been updated with an English-language version.
Uploading Ploutus to the ATM is as easy as accessing the CD-ROM drive or the USB drive on the machine. In previous operations, criminals picked the locks on the ATMs to access the drives, or even bored holes in the machine's casing and covered up the openings.
Next, the criminals must hook a specially configured mobile phone to the ATM using USB tethering, which allows the money machine and the cell phone to share an internet connection, but also keeps the mobile device charging indefinitely.
Now the criminals can send SMS command messages to the mobile phone in the ATM, which will be converted into network packets and forwarded to the ATM, Daniel Regalado, a Symantec security researcher, wrote in the post.
“As soon as the compromised ATM receives a valid TCP or UDP packet from the phone, the NPM will parse the packet and search for the number “5449610000583686” at a specific offset within the packet in order to process the whole package of data,” Regalado wrote. “Once that specific number is detected, the NPM will read the next 16 digits and use them to construct a command line to run Ploutus.”
The end result is that the ATM almost instantly dispenses however much cash the malware is preconfigured to spit out, according to the post, which adds that criminal operators typically work in tandem with money mules to maximize profits.
Using full disk encryption, preventing booting from unauthorized USB sticks and CD-ROMs, and providing adequate physical defense and surveillance will help slow down criminals, Regalado wrote, but updating to Windows 7 or 8 from Windows XP seems to be the most prominent suggestion.
Microsoft will no longer be supporting Windows XP starting next month and, according to various reports, the popular operating system is being used in 95 percent of ATMs around the world.
In a Monday email correspondence, Charles Henderson, director at Trustwave, a security company that helped analyze Ploutus back in October 2013, told SCMagazine.com that the lack of support for Windows XP may create serious security weaknesses, but added that it is not the only issue.
“In our penetration tests against ATMs, many of our most successful attacks have not been OS-dependent,” Henderson said. “Vectors involving man-in-the-middle (MITM) attacks on the ATM network have been more effective and less time consuming than attacks against the underlying OS.”
The crooks begin by loading ATM malware into the cash machine. In the Monday post, Symantec used Ploutus, a piece of malware observed circulating Mexico in October 2013 that was later discovered to have been updated with an English-language version.
Uploading Ploutus to the ATM is as easy as accessing the CD-ROM drive or the USB drive on the machine. In previous operations, criminals picked the locks on the ATMs to access the drives, or even bored holes in the machine's casing and covered up the openings.
Next, the criminals must hook a specially configured mobile phone to the ATM using USB tethering, which allows the money machine and the cell phone to share an internet connection, but also keeps the mobile device charging indefinitely.
Now the criminals can send SMS command messages to the mobile phone in the ATM, which will be converted into network packets and forwarded to the ATM, Daniel Regalado, a Symantec security researcher, wrote in the post.
“As soon as the compromised ATM receives a valid TCP or UDP packet from the phone, the NPM will parse the packet and search for the number “5449610000583686” at a specific offset within the packet in order to process the whole package of data,” Regalado wrote. “Once that specific number is detected, the NPM will read the next 16 digits and use them to construct a command line to run Ploutus.”
The end result is that the ATM almost instantly dispenses however much cash the malware is preconfigured to spit out, according to the post, which adds that criminal operators typically work in tandem with money mules to maximize profits.
Using full disk encryption, preventing booting from unauthorized USB sticks and CD-ROMs, and providing adequate physical defense and surveillance will help slow down criminals, Regalado wrote, but updating to Windows 7 or 8 from Windows XP seems to be the most prominent suggestion.
Microsoft will no longer be supporting Windows XP starting next month and, according to various reports, the popular operating system is being used in 95 percent of ATMs around the world.
In a Monday email correspondence, Charles Henderson, director at Trustwave, a security company that helped analyze Ploutus back in October 2013, told SCMagazine.com that the lack of support for Windows XP may create serious security weaknesses, but added that it is not the only issue.
“In our penetration tests against ATMs, many of our most successful attacks have not been OS-dependent,” Henderson said. “Vectors involving man-in-the-middle (MITM) attacks on the ATM network have been more effective and less time consuming than attacks against the underlying OS.”
訂閱:
文章 (Atom)