AF September 2013 ~ dynamicSainsIT

My Name Is Khairul ilham

Iam study at STMIK AMIKOM YOGYAKARTA

I am a Linux User

wish i can make my own linux some day

use your skill to prove their is a losser

read this blog's and use your imagine to make it real Networker

Networking is the most interesting hooby

I love networking more than anything.

hacker is not crime

hacker can help the system admin to make system strong form thread.

Rabu, 25 September 2013

Install Proxy Server di Debian 6.0.5 auth. login

Install Proxy di Server Debian 6.0.5
Proxy yang saya konfigurasi ini dapat memblokir website tertentu dan membuat autentifikasi pada Squid tersebut agar ketika user masuk kedalam Proxy maka Proxy tersebut kan meminta username dan password Squid tersebut.

Install Squid
# apt-get install squid

Jika sudah kita matikan squidnya dan edit squid.conf
# /etc/init.d/squid stop
htpasswd /etc/squid/passwd [username]
# dpkg -L squid | grep nsca_auth
maka hasilnya:
/usr/lib/squid/ncsa_auth


# nano /etc/squid/squid.conf


Kita cari dan rubah file ini
cache_mem 8 (hilangkan tanda #)
cache_mgr admin 
(hilangkan tada #)
visible_hostname admin 
(hilangkan tanda #)
acl localnet src 172.16.20.0/24
acl situs url_regex -i "/etc/squid/blok.txt"

auth_param basic program /usr/lib/squid/ncsa_auth /etc/squid/passwd
auth_param basic children 5
auth_param basic realm Squid proxy-caching web server
acl ncsa_users proxy_auth REQUIRED

http_access deny situs
http_access allow ncsa_users
http_access allow localnet
http_access allow localhost

http_access deny situs 
(terdapat 2 deny all hilangkan 1)

Jika sudah disave lalu kita lanjut

# nano /etc/squid/blokir.txt

isikan situs yang akan anda blokir

facebook.com
youtube.com
porn

xxx
Jika sudah disave lalu lanjut
# squid -z
jika ada error maka terjadi kesalahan dan koreksi lagi squid.confnya
jika ada tulisan swap direktori blablabla maka berhasil

jika sudah reboot komputer Server anda lalu setting IP proxy di Browser Client anda dengan port 3128 dan IP Server Proxy tersebut dan centang semuanya .