剛看到下面這篇資訊,我怒了。
台灣大攜手網秦科技行動防毒服務 個人資安嚴密把關:
http://corp.taiwanmobile.com/press-release/news/press_20110803_353756.html
在大陸臭名遠洋的防毒軟體“網秦”與台灣大哥大攜手,是想一起攜手來詐騙就對了。
2011年3月15日大陸13億人共同在看的CCTV-1播出的就是“網秦”如何自導自演,自動下載木馬程式後,讓用戶付費更新後清除木馬。難受台灣大哥大的高層在與對方攜手時,不會去了解相關資訊的嗎?
以下為大陸網易上轉載來的資訊:
以下為大陸央視3·15上關於“網秦”的詳細文字解說:
我不懂台灣大哥大攜手是否有其他目的,但對於這樣的防毒軟體公司,已經在信譽上為零的公司,還要與他攜手。您是不怕把自己手也給弄髒嗎?
目前網秦研發的“防毒軟體”可以在Symbian,Android,WM,BlackBerry,為了您朋友的安全,請大家對身邊有智慧型手機的朋友及家人轉載本內容
聲明:以上內容的真實性我不能保證,自己沒有勇氣去測試這樣的軟體,但大陸13億觀眾的CCTV可以保證,而且13億人都知道這條資訊。本人只是轉述內容及個人心中的不平。
2011-08-06
2011-06-03
VIM for Python 自動縮排設定
將以下程式碼加入 ~/.vimrc
完整步驟如下:
如果 沒有 ~/.vimrc 覆製 /usr/share/vim/vim73/vimrc_example.vim 成 ~/.vimrc
編輯~/.vimrc
function! s:python_custom() function! s:man(keyword) execute '!pydoc ' . a:keyword endfunction setlocal tabstop=4 expandtab shiftwidth=4 setlocal foldmethod=indent foldcolumn=4 foldlevel=3 foldnestmax=3 command! -nargs=1 Man call s:man() cnoremap K :!pydocendfunction if has("autocmd") autocmd Filetype python call s:python_custom() endif
完整步驟如下:
如果 沒有 ~/.vimrc 覆製 /usr/share/vim/vim73/vimrc_example.vim 成 ~/.vimrc
$ cp /usr/share/vim/vim73/vimrc_example.vim ~/.vimrc
編輯~/.vimrc
$ sudo vi ~/.vimrc
在 ~/.vimrc 檔案後面加入上面的程式碼
function! s:python_custom()
function! s:man(keyword)
execute '!pydoc ' . a:keyword
endfunction
setlocal tabstop=4 expandtab shiftwidth=4
setlocal foldmethod=indent foldcolumn=4 foldlevel=3 foldnestmax=3
command! -nargs=1 Man call s:man()
cnoremap K :!pydoc
endfunction
if has("autocmd")
autocmd Filetype python call s:python_custom()
endif
Ubuntu 安裝 PostgreSQL 8.04
安裝 postgresql
更改資料庫 postgres 預設密碼 方法一
更改資料庫 postgres 預設密碼 方法二
更改系統帳號 postgres 密碼
經過上面步驟之後就可以透過 command-line 和 pgAdmin 使用新的密碼連入資料庫伺服器。但在使用pgAdmin之前還應該將 PostgresSQL admin pack 設定好,以啟用 pgAdmin 更好的 logging 和 monitoring 工具,使用下面命令設定:
修改設定,讓資料庫能接受遠端連線(Access from Remotely)(非必需)
儲存並關閉檔案
設定誰可以連線
Now for the final step, we must define who can access the server. This is all done using the pg_hba.conf file. (The following advice can also be given to you - plus you don’t even need to figure out IP addresses and subnet masks - from the latest versions of pgAdmin (1.6.x). But it doesn’t hurt to know how things work).
Comment out, or delete the current contents of the file, then add this text to the bottom of the file:
and in the last line, add in your subnet mask (i.e. 255.255.255.0) and the IP address of the machine that you would like to access your server (i.e. 125.232.82.46). However, if you would like to enable access to a range of IP addresses, just substitute the last number for a zero and all machines within that range will be allowed access (i.e. 125.232.192.0 would allow all machines with an IP address 125.232.192.x to use the database server).
That’s it, now all you have to do is restart the server:
to
And all should be working.
原文:
http://hocuspokus.net/2008/05/install-postgresql-on-ubuntu-804/
sudo apt-get install postgresql postgresql-client postgresql-contrib
如需要 GUI 管理工具可以安裝 pgadmin3sudo apt-get install pgadmin3
更改資料庫 postgres 預設密碼 方法一
sudo su postgres -c psql template1
template1=# ALTER USER postgres WITH PASSWORD 'newpassword';
template1=# \q
template1=# ALTER USER postgres WITH PASSWORD 'newpassword';
template1=# \q
更改資料庫 postgres 預設密碼 方法二
sudo su postgres
postgres@local:/$ psql
psql (8.4.8)
Type "help" for help.
postgres=# select * from pg_shadow;
密碼欄位應該是空值
postgres=# alter user postgres with password 'newpassword';
postgres=# \q
離開psql
postgres@local:/$ exit
離開 postgres 帳號
postgres@local:/$ psql
psql (8.4.8)
Type "help" for help.
postgres=# select * from pg_shadow;
密碼欄位應該是空值
postgres=# alter user postgres with password 'newpassword';
postgres=# \q
離開psql
postgres@local:/$ exit
離開 postgres 帳號
更改系統帳號 postgres 密碼
sudo passwd -d postgres
sudo su postgres -c passwd
輸入新密碼sudo su postgres -c passwd
經過上面步驟之後就可以透過 command-line 和 pgAdmin 使用新的密碼連入資料庫伺服器。但在使用pgAdmin之前還應該將 PostgresSQL admin pack 設定好,以啟用 pgAdmin 更好的 logging 和 monitoring 工具,使用下面命令設定:
sudo su postgres -c psql < /usr/share/postgresql/8.4/contrib/adminpack.sql
修改設定,讓資料庫能接受遠端連線(Access from Remotely)(非必需)
sudo vi /etc/postgresql/8.4/main/postgresql.conf
#listen_addresses = 'localhost'
tolisten_addresses = '*'
#password_encryption = on
topassword_encryption = on
儲存並關閉檔案
設定誰可以連線
Now for the final step, we must define who can access the server. This is all done using the pg_hba.conf file. (The following advice can also be given to you - plus you don’t even need to figure out IP addresses and subnet masks - from the latest versions of pgAdmin (1.6.x). But it doesn’t hurt to know how things work).
sudo vi /etc/postgresql/8.4/main/pg_hba.conf
Comment out, or delete the current contents of the file, then add this text to the bottom of the file:
# DO NOT DISABLE! # If you change this first entry you will need to make sure that the # database # super user can access the database using some other method. # Noninteractive # access to all databases is required during automatic maintenance # (autovacuum, daily cronjob, replication, and similar tasks). # # Database administrative login by UNIX sockets local all postgres ident sameuser # TYPE DATABASE USER CIDR-ADDRESS METHOD # "local" is for Unix domain socket connections only local all all md5 # IPv4 local connections: host all all 127.0.0.1/32 md5 # IPv6 local connections: host all all ::1/128 md5 # Connections for all PCs on the subnet # # TYPE DATABASE USER IP-ADDRESS IP-MASK METHOD host all all [ip address] [subnet mask] md5
and in the last line, add in your subnet mask (i.e. 255.255.255.0) and the IP address of the machine that you would like to access your server (i.e. 125.232.82.46). However, if you would like to enable access to a range of IP addresses, just substitute the last number for a zero and all machines within that range will be allowed access (i.e. 125.232.192.0 would allow all machines with an IP address 125.232.192.x to use the database server).
That’s it, now all you have to do is restart the server:
to
sudo /etc/init.d/postgresql restart
And all should be working.
原文:
http://hocuspokus.net/2008/05/install-postgresql-on-ubuntu-804/
2011-06-01
2011-05-31
Ubuntu Server i386 安裝完 CLI 中文顯示亂碼
修改
修改
$sudo vi /var/lib/locales/supported.d/local
改為en_US.UTF-8 UTF-8
修改
$sudo /etc/default/locale
改為LANG="en_US.UTF-8"
LANGUAGE="en_US:en"
LANGUAGE="en_US:en"
2011-05-11
Android 多國語系
Environment:
Win2003 + Eclipse + SDK Platform Android 2.2, API 8, revision 2
語系資源檔路徑:Project/res/[values]
[values]語系目錄名對應如下:
預設:values
英文: values-en
繁體中文: values-zh-rTW
簡體中文: values-zh-rCN
日文: values-ja
美式英文: values-en-rUS
英式英文: values-en-rUK
當程式執行時會依據手機的語系設定載入對應的語系資源,
Configuration conf = res.getConfiguration();
conf.locale = Locale.TRADITIONAL_CHINESE;//中文
DisplayMetrics dm = res.getDisplayMetrics();
res.updateConfiguration(conf, dm);
======Code End=============================
==2011/05/11==
Win2003 + Eclipse + SDK Platform Android 2.2, API 8, revision 2
語系資源檔路徑:Project/res/[values]
[values]語系目錄名對應如下:
預設:values
英文: values-en
繁體中文: values-zh-rTW
簡體中文: values-zh-rCN
日文: values-ja
美式英文: values-en-rUS
英式英文: values-en-rUK
當程式執行時會依據手機的語系設定載入對應的語系資源,
測試的時候可在 onCreate() 中加入以下程式碼測試不同的語系執行結果
Resources res = getResources();Configuration conf = res.getConfiguration();
conf.locale = Locale.TRADITIONAL_CHINESE;//中文
DisplayMetrics dm = res.getDisplayMetrics();
res.updateConfiguration(conf, dm);
======Code=============================
package tw.cww.tipcalculator;
import java.util.Locale;
import android.app.Activity;
import android.content.res.Configuration;
import android.content.res.Resources; import android.os.Bundle;
import android.util.DisplayMetrics;
public class TipCalculator extends Activity {
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
Resources res = getResources();
Configuration conf = res.getConfiguration();
conf.locale = Locale.TRADITIONAL_CHINESE;//中文
DisplayMetrics dm = res.getDisplayMetrics();
res.updateConfiguration(conf, dm);
setContentView(R.layout.main);
}
}
======Code End=============================
==2011/05/11==
2011-04-28
記住這8句話,你至少成熟5歲!
1. 如果你不喜歡現在的工作,要麼辭職不幹,要麼就閉嘴不言。 初出茅廬,往往眼高手低,心高氣傲,大事做不了,小事不願做。 不要養成挑三揀四的習慣。 不要雨天煩打傘,不帶傘又怕淋雨,處處表現出不滿的情緒。 記住,不做則已,要做就要做好。
2. 每個人都有孤獨的時候。 要學會忍受孤獨,這樣才會成熟起來。 年輕人嘻嘻哈哈、打打鬧鬧慣了,到了一個陌生的環境,面對形形色色的人和事,一下子不知所措起來,有時連一個可以傾心說話的地方也沒有。 這時,千萬別浮躁,學會靜心,學會忍受孤獨。 在孤獨中思考,在思考中成熟,在成熟中昇華。 不要因為寂寞而亂了方寸,而去做無聊無益的事情,白白浪費了寶貴的時間。
3. 不要像玻璃那樣脆弱。 有的人眼睛總盯著自己,所以長不高看不遠;總是喜歡怨天尤人,也使別人無比厭煩。 沒有苦中苦,哪來甜中甜? 不要像玻璃那樣脆弱,而應像水晶一樣透明,太陽一樣輝煌,鑽石一樣堅強。 既然睜開眼睛享受風的清涼,就不要埋怨風中細小的沙粒。
4. 管住自己的嘴巴。 不要談論自己,更不要議論別人。 談論自己往往會自大虛偽,在名不副實中失去自己。 議論別人往往陷入雞毛蒜皮的是非口舌中糾纏不清。 每天下班後和你的那些同事朋友喝酒聊天可不是件好事,因為,這中間往往會把議論同事、朋友當做話題。 背後議論人總是不好的,尤其是議論別人的短處,這些會降低你的人格。
5. 機會從不會“失掉”,你失掉了,自有別人會得到。 不要凡事在天,守株待兔,更不要寄希望于“機會”。 機會只不過是相對于充分準備而又善於創造機會的人而言的。 也許,你正為失去一個機會而懊悔、埋怨的時候,機會正被你對面那個同樣的“倒楣鬼”給抓住了。 沒有機會,就要創造機會,有了機會,就要巧妙地抓住。
6. 若電話老是不響,你該打出去。 很多時候,電話會給你帶來意想不到的收穫,它不是花瓶,僅僅成為一種擺設。 交了新朋友,別忘了老朋友,朋友多了路好走。 交際的一大訣竅就是主動。 好的人緣好的口碑,往往助你的事業更上一個臺階。
7. 千萬不要因為自己已經到了結婚年齡而草率結婚。 想結婚,就要找一個能和你心心相印、相輔相攜的伴侶。 不要因為放縱和遊戲而戀愛,不要因為戀愛而影響工作和事業,更不要因一樁草率而失敗的婚姻而使人生受阻。 感情用事往往會因小失大。
8. 寫出你一生要做的事情,把單子放在皮夾裏,經常拿出來看。 人生要有目標,要有計劃,要有提醒,要有緊迫感。 一個又一個小目標串起來,就成了你一生的大目標。 生活富足了,環境改善了,不要忘了皮夾裏那張看似薄薄的單子。
作者: 王寶露
2. 每個人都有孤獨的時候。 要學會忍受孤獨,這樣才會成熟起來。 年輕人嘻嘻哈哈、打打鬧鬧慣了,到了一個陌生的環境,面對形形色色的人和事,一下子不知所措起來,有時連一個可以傾心說話的地方也沒有。 這時,千萬別浮躁,學會靜心,學會忍受孤獨。 在孤獨中思考,在思考中成熟,在成熟中昇華。 不要因為寂寞而亂了方寸,而去做無聊無益的事情,白白浪費了寶貴的時間。
3. 不要像玻璃那樣脆弱。 有的人眼睛總盯著自己,所以長不高看不遠;總是喜歡怨天尤人,也使別人無比厭煩。 沒有苦中苦,哪來甜中甜? 不要像玻璃那樣脆弱,而應像水晶一樣透明,太陽一樣輝煌,鑽石一樣堅強。 既然睜開眼睛享受風的清涼,就不要埋怨風中細小的沙粒。
4. 管住自己的嘴巴。 不要談論自己,更不要議論別人。 談論自己往往會自大虛偽,在名不副實中失去自己。 議論別人往往陷入雞毛蒜皮的是非口舌中糾纏不清。 每天下班後和你的那些同事朋友喝酒聊天可不是件好事,因為,這中間往往會把議論同事、朋友當做話題。 背後議論人總是不好的,尤其是議論別人的短處,這些會降低你的人格。
5. 機會從不會“失掉”,你失掉了,自有別人會得到。 不要凡事在天,守株待兔,更不要寄希望于“機會”。 機會只不過是相對于充分準備而又善於創造機會的人而言的。 也許,你正為失去一個機會而懊悔、埋怨的時候,機會正被你對面那個同樣的“倒楣鬼”給抓住了。 沒有機會,就要創造機會,有了機會,就要巧妙地抓住。
6. 若電話老是不響,你該打出去。 很多時候,電話會給你帶來意想不到的收穫,它不是花瓶,僅僅成為一種擺設。 交了新朋友,別忘了老朋友,朋友多了路好走。 交際的一大訣竅就是主動。 好的人緣好的口碑,往往助你的事業更上一個臺階。
7. 千萬不要因為自己已經到了結婚年齡而草率結婚。 想結婚,就要找一個能和你心心相印、相輔相攜的伴侶。 不要因為放縱和遊戲而戀愛,不要因為戀愛而影響工作和事業,更不要因一樁草率而失敗的婚姻而使人生受阻。 感情用事往往會因小失大。
8. 寫出你一生要做的事情,把單子放在皮夾裏,經常拿出來看。 人生要有目標,要有計劃,要有提醒,要有緊迫感。 一個又一個小目標串起來,就成了你一生的大目標。 生活富足了,環境改善了,不要忘了皮夾裏那張看似薄薄的單子。
作者: 王寶露
訂閱:
文章 (Atom)