UTC=false
ARC=false
本文為鏡像,原貼在此:http://www.btk4ever.com/?p=10443
posted @ 2009-04-28 09:35 生活在別處 閱讀(2177) | 評(píng)論 (0) | 編輯 收藏
posts - 34, comments - 6, trackbacks - 0, articles - 0 |
||
RedHat Linux操作系統(tǒng)修改時(shí)區(qū)的方法
Most
modern Linux distributions have user-friendly programs to set the
timezone, often accesible through the program menus or right-clicking
the clock in a desktop environment such as KDE or GNOME. Failing that
it’s possible to manually change the system timezone in Linux in a few
short steps.
Steps
1. Logged
in as root, check which timezone your machine is currently using by
executing `date`. You’ll see something like “Mon 17 Jan 2005 12:15:08
PM PST -0.461203 seconds”, PST in this case is the current timezone.
2. Change
to the directory to /usr/share/zoneinfo, here you will find a list of
time zone regions. Choose the most appropriate region, if you live in
Canada or the US this directory is the “Americas” directory.
3. If
you wish, backup the previous timezone configuration by copying it to a
different location. Such as `mv /etc/localtime /etc/localtime-old`.
4. Create
a symbolic link from the appropiate timezone to /etc/localtime.
Example: `ln -s /usr/share/zoneinfo/Europe/Amsterdam /etc/localtime`.
5. If
you have the utility rdate, update the current system time by executing
`/usr/bin/rdate -s time.nist.gov`. (This step can be skip!)
6. Set the ZONE entry in the file /etc/sysconfig/clock file (e.g. “America/Los_Angeles”)
7. Set the hardware clock by executing: ` /sbin/hwclock –systohc`
Tips
· On
some versions of RedHat Linux, Slackware, Gentoo, SuSE, Debian, Ubuntu,
and anything else that is “normal”, the command to display and change
the time is ‘date’, not ‘clock’
· On
RedHat Linux there is a utility called “Setup” that allows one to
select the timezone from a list, but you must have installed the
‘redhat-config-date’ package.
Warnings
· Some applications (such as PHP) have separate timezone settings from the system timezone.
· On
some systems, /etc/localtime is actually a symlink to the appropriate
file under the /usr/share/zoneinfo directory (rather than a copy of
that file).
· On
some systems, there is a system utility provided that will prompt for
the correct timezone and make the proper changes to the system
configuration. For example,Debianprovides the “tzsetup” utility.
Here is an example of changing the timezone: (Logged in as root)
In order to manually change the timezone, you can edit the /etc/sysconfig/clockfile and then make a new soft link to /etc/localtime. Here is an example of changing the timezone manually to “America/Denver”:
1. Select the appropriate time zone from the /usr/share/zoneinfo directory. Time zone names are relative to that directory. In this case, we will select “America/Denver”
2. Edit the /etc/sysconfig/clocktext file so that it looks like this:
ZONE=”America/Denver”
UTC=true
ARC=false
Of course, this assumes that your hardware clock is running UTC time…
3. Delete the following file: /etc/localtime (backup it when you need it !)
4. Create a new soft link for /etc/localtime. Here is an example of step 3 and step 4:
# cd /etc
# ls -al localtime
lrwxrwxrwx 1 root root 39 Mar 28 07:00 localtime -> /usr/share/zoneinfo/America/Los_Angeles
# rm /etc/localtime
# ln -s /usr/share/zoneinfo/America/Denver /etc/localtime
# ls -al localtime
lrwxrwxrwx 1 root root 34 Mar 28 08:59 localtime -> /usr/share/zoneinfo/America/Denver
# date
Fri Mar 28 09:00:04 MST 2003
針對(duì)中國時(shí)區(qū),修改操作如下
1. 修改文件 /etc/sysconfig/clock內(nèi)容:
ZONE=Asia/Shanghai
UTC=false ARC=false 2. rm /etc/localtime
ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
還有其他方法修改時(shí)區(qū),不過是基于圖形化界面的命令: tzselect 、 timeconfig本文為鏡像,原貼在此:http://www.btk4ever.com/?p=10443 posted @ 2009-04-28 09:35 生活在別處 閱讀(2177) | 評(píng)論 (0) | 編輯 收藏 朋友搬到個(gè)新地方,沒有寬帶了,但是能收到些加密的無線網(wǎng)絡(luò),挺想蹭網(wǎng)的,本人由于是所謂“挨踢”人士,自當(dāng)義不容辭出手相助。 我也只是想了解下WEP破解這事,目的也只是提醒大家一下要加強(qiáng)無線網(wǎng)絡(luò)安全,千萬不要干啥非法的事情,當(dāng)然有本事的話,就把屁股擦干凈。 其實(shí)前兩年我就知道WEP加密是極不安全的,而且也出于好奇做過密鑰破解的嘗試,但是由于破解軟件特別挑網(wǎng)卡,結(jié)果自然就是半途而廢了。這次到網(wǎng)上 再度查了點(diǎn)相關(guān)資料,發(fā)現(xiàn)這事情已然變得相當(dāng)?shù)暮?jiǎn)單了,基本上只需要 BackTrack3 就可以搞定了。Backtrack 是一個(gè)黑客操作系統(tǒng),其實(shí)也算是一個(gè)linux的黑客版,主要是安裝了很多實(shí)用的軟件和黑客工具,偏向于安全侵入方面的。 我是下載了一個(gè)BackTrack3 的usb版本,并且下了最新的掃描工具spoonwep2,系統(tǒng)自帶的是spoonwep也能用,但是據(jù)說新版更好使,更方面。整個(gè)過程挺簡(jiǎn)單的,機(jī)器設(shè) 置成usb可引導(dǎo)啟動(dòng),然后啟動(dòng)進(jìn)入usb上的BackTrack系統(tǒng),都是圖形界面的,打開spoonwep2工具,掃描周圍的無線信號(hào),選擇信號(hào)強(qiáng) 的,有客戶端連接,并且DATA包比較多的信號(hào)來破解吧,這樣應(yīng)該可以快點(diǎn),據(jù)說XX分鐘就能破解了。沒有客戶端連接的無線信號(hào),據(jù)說有些AP也是同樣可 以破解的,無非是攻擊方式的變化以及花費(fèi)的時(shí)間更長(zhǎng)而已。 我的經(jīng)歷是,晚上10點(diǎn)多開始破一個(gè)無線信號(hào),等了一個(gè)多小時(shí),進(jìn)度開始變緩慢,因?yàn)楸緛磉B著的兩個(gè)客戶端下線了,估計(jì)困搞去了…,很無奈,我也不 能傻等,只得也睡覺去了。第二天早上起來,1o點(diǎn)多的時(shí)候,才抓滿了要求的數(shù)據(jù)包,整個(gè)密鑰破解過程倒是瞬間完成,然后我看到的密碼是”1111111″ ,囧 rz,看來設(shè)無線密碼的人都很懶。這個(gè)過程還是挺漫長(zhǎng)的,可能是沒選擇對(duì)正確的攻擊方式,導(dǎo)致數(shù)據(jù)包獲取的過程很長(zhǎng)。假如有客戶端在BT下載,估計(jì)快很 多,要是只是qq聊天,那就要耗很久了。不過整個(gè)過程,已經(jīng)相當(dāng)?shù)纳倒匣恕? 這事也不能說的太細(xì),想了解詳細(xì)的人,網(wǎng)上查去吧,順便提供一個(gè)教程。 至于如何加強(qiáng)無線安全,有這么幾點(diǎn)(網(wǎng)上找的) 如果你需要你的AP很難被破解,建議: 還有其他幾點(diǎn)也可以做,如減低信號(hào)、關(guān)閉DHCP、MAC地址綁定,當(dāng)然這些措施也只是增加難度而已。 最后提一下,蹭網(wǎng)是有風(fēng)險(xiǎn)的,無線信號(hào)不加密的,人家未必就是大善人或者菜鳥,而且還有人專門釣魚的,加大信號(hào),設(shè)置簡(jiǎn)單密碼,專門等蹭網(wǎng)的人來,數(shù)據(jù)包一抓,等著被玩吧。 本文為鏡像,原貼在此:http://www.btk4ever.com/?p=10423
posted @ 2009-04-28 09:33 生活在別處 閱讀(1196) | 評(píng)論 (0) | 編輯 收藏 |
||