Skip to content

Instantly share code, notes, and snippets.

@peter279k
Last active July 20, 2020 03:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save peter279k/3cca83e196940d10b8fb45f5900b890d to your computer and use it in GitHub Desktop.
Save peter279k/3cca83e196940d10b8fb45f5900b890d to your computer and use it in GitHub Desktop.
The references about SmartMeterSecurityTest (Including SmartMeter)

Penetration Test Tool

  • https://github.com/rsmusllp/termineter

    • This is the most common configuration found in North America.
    • Termineter communicates with Smart Meters via a connection using an ANSI type-2 optical probe with a serial interface.
    • It supports C1218, C1219 and C1219-2007 protocols.
    • 美規的智慧電表滲透測試工具

    工具操作概覽

論文

Analysis of the Security Anomalies in the Smart Metering Infrastructure and Its Impact on Energy Profiling and Measurement

  • India 印度的智慧電網架構
  • https://indiasmartgrid.org/standard.php
  • 走歐規的IEC
  • 2016年發表的論文
  • 這篇著重在智慧電表的加密資料傳輸與相關的安全性
    • IEC 62051 智慧電表資料交換格式標準
    • IEC 62056 定義電表資料交換方式
    • IEC 62351 安全智慧電表資料交換與溝通,並搭配應用層上的RFC 3394與AES Key Wrap Algorithm
  • 展示建置的實驗環境與架構

電表構造

電表設備

AMI實驗架構環境

Implementation Aspects of MeterGoat, a Smart Meter Security Training Platform

  • 2014年發表的論文
  • Tool Demo 工具平台發表
  • 靈感來自 WebGoat,一個由OWASP組織所發表的網頁應用程式安全教學平台
  • MeterGoat,主要是建立一個智慧電表的教學平台
  • 裝置為:MSP430F5438 microcontroller
  • Sample Lessons
    • Physical Tampering
    • Flawed Authentication
    • Improper Cryptography

MeterGoat Lab

Anti-Tampering

MSP430's memory organization

Memory Dump

Memory Dump2

Memory Dump3

Entropy Level Memory Dump

Smart Meter Security: Vulnerabilities, Threat Impacts, and Countermeasures

  • 2019年發表的論文

  • 主要是在介紹智慧電網可能會發生的安全議題

  • AMI 架構一覽介紹

    • 網路相關,傳輸介面架構介紹
    • 資料管理系統
  • AMI安全議題 (Security Issues)

    • Smart Meter Security 智慧電表安全

    Point-MultiPoint Network Topology

    Mesh Network Topology

    AMI MAIN COMPONENTS AND SUBCOMPONENTS

  • Data Collector Security

    • DMS做智慧電表資料收集可能遇到的問題

    Data Collector Security issues

  • Security Controls and Countermeasures

    • Encryption (e.g. AES, RSA) MAC (Message Authentication Code) 訊息驗證
    • Authentication Mechanism (認證機制) public-private key
    • ARP (位址解析攻擊)
    • DoS (阻斷式攻擊)

AMI Penetration Test Plan

  • 由(美國)國家電力網路安全組織 (NESCOR) 所建立的滲透測試計畫書模板 National Electric Sector Cybersecurity Organization Resource
  • 此計畫書模板定義與描述該如何對AMI整個系統架構做滲透測試

Level

Typical Penetration Testing Plan Process

  • (補充架構圖 常見AMI架構圖)

AMI System Test Offering

  • 只有二頁,都在講該如何做測試與測試架構框架圖
  • Framework for AMI Testing Testing
  • 測試都是一塊塊分開做測試
    • Head End System
    • MDM System

結論

  • 智慧電表提及與安全相關的議題可以分成兩種:
    • 一種是用原本的安全標準的導入並在論文中提到
      • 白箱測試,開發上想到什麼資安問題並加上相關功能做到防禦
    • 建置電表相關的資安訓練平台(靶機),並讓使用者透過訓練平台可以學到如何對智慧電表做滲透測試等相關的黑箱測試
      • e.g. 滲透測試,不知道架構與source code長怎樣,以平台為出發點進行攻擊與檢測
    • 對既有的智慧電網架構進行安全性分析,並提出可能有的漏洞威脅與可能會遭受的攻擊
    • 提出滲透測試計畫 (AMI Penetration Test Plan),其內容規範涵蓋甚廣,如嵌入式裝置到平台都有相關滲透測試任務,定義,嚴重等級以及目標

個人想法

  • 資安訓練測試平台建置可能?(建置靶機環境)供人訓練與使用 類似 MeterGoat
  • Bug Bounty 漏洞獎勵計畫之困難度? 國外也很少看到以智慧電網當作漏洞獎勵這樣的案例,可能原因:
    • 滲透測試做過了嗎?跳過滲透測試直接朝向Bug Bounty? 還是是同時進行?
    • 環境建置問題,建置環境成本較高與困難度也高
    • 若要建置,從架構中抓其中一部分出來建置,而非建置一個與production一樣的架構出來,如:只建置電表裝置到遠端資料管理系統架構
    • Divide and Conquer 將架構拆解成多段,或是注重在某段的滲透測試以及 Bug Bounty Program
      • 這樣需要知道目前現階段台灣的智慧電網整體系統架構
      • 目標要設定好,e.g. 裝置之間的通訊? (Meter-to-Aggregator, Aggregator-to-Headend) 智慧電表裝置本身的漏洞檢測?
  • 國內跟裝置有關的Bug Bounty Program
    • 群暉 相關參考網址
      • NAS 上的各種應用,如DSM (Disk Station Manager),DSM上可以取得與使用的套件
      • 網站系統上的漏洞
      • Bug Bounty 規範
      • https://www.ithome.com.tw/news/126021
        • 節錄報導
        • 他們也積極參與資安相關的活動。例如,2015年,他們在HITCON社群場設立了攤位,並且舉行了小活動,讓與會者只要在他們的測試平臺上,可以找出任意存取使用者資料等各式安全漏洞,就會得到他們的NAS設備作為獎勵。
    • QNAP 威聯通科技
  • Bug Bounty Hunter & 企業面對Bug bounty Program的心態
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment