ข่าว: ข่าวประกาศ

  • 21 เมษายน 2024, 01:18:42

เข้าสู่ระบบด้วยชื่อผู้ใช้ รหัสผ่าน และระยะเวลาในเซสชั่น

ผู้เขียน หัวข้อ: วิธีการ Bypass บาง WebSite ไม่ให้ผ่าน Proxy  (อ่าน 24949 ครั้ง)

admin

  • Administrator
  • Hero Member
  • *****
  • กระทู้: 3820
    • ดูรายละเอียด
    • อีเมล์
วิธีการ Bypass บาง WebSite ไม่ให้ผ่าน Proxy
« เมื่อ: 18 สิงหาคม 2008, 14:48:32 »
เนื่องจากว่า Proxy มีทั้งข้อดีและข้อเสีย

- ข้อดี คือ ทำให้เวปเร็วขึ้น
- แต่ข้อเสีย ก็คือ ทำให้เวปบางเวปช้าผิดปกติ หรือเข้าไม่ได้ หรือมีปัญหาเมื่อใช้งานผ่าน proxy

ยกตัวอย่างเช่น

การใช้งาน Web ข่าว www.thairath.co.th มาช้า หรือมาไม่ครบ ขาดๆ
หรือการเข้า Web www.icafeplus.net ไม่ได้  เป็นต้น

สามารถแก้ไขได้ดังนี้

ก่อนอื่นจะต้องทำการตรวจสอบก่อนว่า เวป ดังกล่าว มี ip อะไร

โดยใช้คำสั่ง nslookup จะได้ว่า

Name:    www.thairath.co.th
Address: 203.151.217.25, 203.151.217.76, 203.151.233.143

Name:   www.icafeplus.net
Address: 61.90.252.113

วิธีการคือ ให้เราทำการ -j ACCEPT ip ดังกล่าว ก่อนจะทำการ -j REDIRECT

โดยสามารถเข้าไปแก้ในไฟล์  /etc/init.d/tproxy.sh

โค๊ด: [Select]
#!/bin/bash

# This file is auto generate by xxxkung script

iptables -t nat -F TPROXY

### Bypass www.icafeplus.net
iptables -t nat -A TPROXY -i eth0 -d 61.90.252.113 -j ACCEPT

### Bypass www.thairath.co.th
iptables -t nat -A TPROXY -i eth0 -d 203.151.217.25 -j ACCEPT
iptables -t nat -A TPROXY -i eth0 -d 203.151.233.143 -j ACCEPT
iptables -t nat -A TPROXY -i eth0 -d 203.151.217.76 -j ACCEPT

### Redirect Trickster
iptables -t nat -A TPROXY -i eth0 -p tcp -d 61.90.203.0/24 --dport 5977 -j REDIRECT --to-port 8080
### Redirect Normal Web Port
iptables -t nat -A TPROXY -i eth0 -p tcp --dport 80 -j REDIRECT --to-port 8080

เป็นต้น

ลองนำไปทดลองกันดูนะครับ
« แก้ไขครั้งสุดท้าย: 18 สิงหาคม 2008, 17:32:50 โดย admin »
<a href="http://www.hadyaiinternet.com/images/inetcafe.swf" target="_blank" rel="noopener noreferrer" class="bbc_link bbc_flash_disabled new_win">http://www.hadyaiinternet.com/images/inetcafe.swf</a>


There are no comments for this topic. Do you want to be the first?