2022年5月8日 星期日

Windows Server關閉不需要的加密通訊方式

 關閉TLS 1.0TSL 1.1SSL 2.0SSL 3.0

  1. Win + R >> enter regedit >> press Enter
  2. 設定以下機碼
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.0\Server]
"Enabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.1\Server]
"Enabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\SSL 2.0\Server]
"Enabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\SSL 3.0\Server]
"Enabled"=dword:00000000

關閉不需要的加密演算法

  1. Win + R >> enter regedit >> press Enter
  2. 設定以下機碼
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Ciphers\RC4 128/128]
"Enabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Ciphers\RC4 40/128]
"Enabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Ciphers\RC4 56/128]
"Enabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Ciphers\Triple DES 168]
"Enabled"=dword:00000000

※請注意:以上變更須重新啟動作業系統!

Content Security Policy

CSP 是內容安全策略(Content Security Policy,簡稱CSP),主要是用來防禦 XSS

 Directive

Directive

範例

描述

default-src

'self' cdn.example.com

預設

script-src

'self' js.example.com

Javascript

style-src

'self' css.example.com

CSS

img-src

'self' img.example.com

圖片

connect-src

'self'

Ajax, Websocket

font-src

font.example.com

字體

object-src

'self'

物件

media-src

media.example.com

媒體

 Source Value

Source Value

範例

說明

*

img-src *

萬用字元, 除了 data: blob: filesystem:

'none'

object-src 'none'

任何資源都不允許

'self'

script-src 'self'

只允許自己同域名

data:

img-src 'self' data:

允許 data 類如 base64 圖片

example.com

img-src example.com

允許指定的域名

*.example.com

img-src *.example.com

允許指定的域名底下的子域名

'unsafe-inline'

script-src 'unsafe-inline'

允許使用 inline 元素,例如樣式屬性,onclick javascriptURI

'unsafe-eval'

script-src 'unsafe-eval'

允許進行不安全的動態程式碼,例如JavaScript eval()

 參考資訊:

  • CSP Evaluator
https://csp-evaluator.withgoogle.com/ 幫你分析你寫的 CSP

 

[詐欺案件]高雄地方法院調解過程

2023/06/30上午代理女兒去做調解,還另外準備了" 刑事附帶民事訴訟狀 ",以防與對方調解不成就加告民事訴訟。 進入調解室,對方是一位律師帶著2位年輕人(被告),告訴人是我女兒及另一位受害年經女生。那2位被告是將銀行帳戶以一個帳戶8萬元賣給詐騙集團(共犯...