顯示具有 SECURITY 標籤的文章。 顯示所有文章
顯示具有 SECURITY 標籤的文章。 顯示所有文章

2015年3月9日 星期一

Authentication vs. Authorization

Authentication mean 


  • Who is user ?
  • And his password is hser?





Authorization mean

  • Is the user can get the file?
  • Is the user have write power?

2012年9月10日 星期一

極光行動 (Operation Aurora)

http://tw.trendmicro.com/tw/support/tech-support/board/tech/article/20120430133619.html

2012年3月5日 星期一

Make

article:

GNU make:



make 內建變數的涵義

$@ Target的檔名

$% 程式庫成員中的檔名元素

$< 第一個prequeite的檔名

$? Timestamp 在Target之後的Prequeite

$^ 所有的Prequeite的檔名 但不包含重複部分

$+ 所有的Prequeite的檔名


$(@D) $(

$(@F) $(



.PHONY in Makefile

Make 主要的工作目標都是針對檔案,所以萬一你定義的工作目標並不是檔案,或是正好與檔案重複的時候,其實是會讓人丈二金剛摸不著頭的。
所以,.PHONY 被用來定義假工作目標,這樣 Make 就知道這不是針對檔案。

Make 預設的假工作目標有:
  • all
  • install
  • clean
  • distclean
  • TAGS
  • info
  • check
Reference:

2010年6月4日 星期五

Browser certificate

from JIM

1. browser certificate is using cert8.db format
{{{
/etc/pki/nssdb/cert8.db
/home/Andy/.evolution/cert8.db
/home/Andy/.mozilla/eclipse/cert8.db
/home/Andy/.mozilla/firefox/ezs1dfr5.default/cert8.db
/home/Andy/.redhat/esc/mlk60whb.default/cert8.db
}}}

2. 可以用 certutil command 作簡單的讀取
{{{
[Andy@t-ap188 JWS]$ certutil -d /home/Andy/.mozilla/firefox/ezs1dfr5.default -K
certutil: Checking token "NSS Certificate DB" in slot "NSS User Private Key and Certificate Services "
< 0> rsa 45c1ecf00b4e5018ef3b49439ad646d3d4dd701f DeHua Chung 179110 的 AS ID

}}}

2010年6月1日 星期二

P12 與 host.pem 和 cert.pem

我們可以有兩種對 key 作法:
1. 將 key.pem 與 hostcert.pem 合成 P12
2. 將 P12 拆成 key.pem 與 hostcert.pem


A. 將 key.pem 與 hostcert.pem 合成 p12
I. 會要求輸入 key.pem passwd
II. 會需要 P12 Export passwd
openssl pkcs12 -export -chain \
-inkey $keyPath/hostkey.pem \
-in $keyPath/hostcert.pem \
-out $keyPath/host.p12 \
-CApath /etc/grid-security/certificates/ \
-name "vt-004"



B. 將 P12 拆成 key.pem 與 hostcert.pem
I 會要輸入 P12 Import passwd
2. 要求建立新的 key.pem passwd
$ openssl pkcs12 -in xxxx.pfx(p12) -clcerts -nokeys -out usercert.pem
$ openssl pkcs12 -in xxxx.pfx(p12) -nocerts -out userkey.pem


C. 可以用 openssl 看 certficate 資訊
{{{
openssl x509 -in 06B3.crt -noout -text

}}}
Note:
1. 有時在將 key 合成 p12 時, 會不用輸入 key passwd(ie. PC host key)
2. 而 P12 被合成有時也可以不要 Export passwd