0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

Chack Pointの元ユーザです。ネットワーク管理者の仕事を離れて、はやいく年月。
仕事では、背kyフリティについて強化しようとしています。

自動車関連のセキュリティを中心に、セキュリティ全体から自動車関連のセキュリティに遅れが生じないように資料を整理中です。

autosar security and crypto
https://qiita.com/kaizen_nagoya/items/7aeba2219725384615cf
の資料を順次、参考文献一覧などを作成予定です。

AUTOSAR 402 Specification of Crypto Service Manager
https://www.autosar.org/fileadmin/standards/R24-11/CP/AUTOSAR_CP_SWS_CryptoServiceManager.pdf

3.1 Input documents & related standards and norms
[1] Requirements on Crypto Stack AUTOSAR_CP_RS_CryptoStack
[2] Glossary AUTOSAR_FO_TR_Glossary
[3] Specification of Crypto Interface AUTOSAR_CP_SWS_CryptoInterface
[4] Specification of Crypto Driver AUTOSAR_CP_SWS_CryptoDriver
[5] Specification of Default Error Tracer AUTOSAR_CP_SWS_DefaultErrorTracer
[6] General Specification of Basic Software Modules AUTOSAR_CP_SWS_BSWGeneral
[7] General Requirements on Basic Software Modules AUTOSAR_CP_RS_BSWGeneral
[8] IETF RFC 5639 – Elliptic Curve Cryptography (ECC) Brainpool Standard Curves and Curve Generation, 2010
https://datatracker.ietf.org/doc/html/rfc5639
[9] IETF RFC 6637 – Elliptic Curve Cryptography (ECC) in OpenPGP, 2012
https://datatracker.ietf.org/doc/html/rfc2863

[8] IETF RFC 5639 – Elliptic Curve Cryptography (ECC) Brainpool Standard Curves and Curve Generation, 2010

7.1. Normative References

[ANSI1] American National Standards Institute, "Public Key
Cryptography For The Financial Services Industry: The
Elliptic Curve Digital Signature Algorithm (ECDSA)", ANSI
X9.62, 2005.
[RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
Requirement Levels", BCP 14, RFC 2119, March 1997.
[RFC5480] Turner, S., Brown, D., Yiu, K., Housley, R., and T. Polk,
"Elliptic Curve Cryptography Subject Public Key
Information", RFC 5480, March 2009.

7.2. Informative References

[ANSI2] American National Standards Institute, "Public Key
Cryptography For The Financial Services Industry: Key
Agreement and Key Transport Using The Elliptic Curve
Cryptography", ANSI X9.63, 2001.
[BJ] Brier, E. and M. Joyce, "Fast Multiplication on Elliptic
Curves through Isogenies", Applied Algebra Algebraic
Algorithms and Error-Correcting Codes, Lecture Notes in
Computer Science 2643, Springer Verlag, 2003.
[BG] Brown, J. and R. Gallant, "The Static Diffie-Hellman
Problem", Centre for Applied Cryptographic Research,
University of Waterloo, Technical Report CACR 2004-10,
2005.
[BRS] Bohli, J., Roehrich, S., and R. Steinwandt, "Key
Substitution Attacks Revisited: Taking into Account
Malicious Signers", International Journal of Information
Security Volume 5, Issue 1, January 2006.
[BSS] Blake, I., Seroussi, G., and N. Smart, "Elliptic Curves in
Cryptography", Cambridge University Press, 1999.
[EBP] ECC Brainpool, "ECC Brainpool Standard Curves and Curve
Generation", October 2005, <http://www.ecc-brainpool.org/
download/Domain-parameters.pdf>.
[ETSI] European Telecommunications Standards Institute (ETSI),
"Algorithms and Parameters for Secure Electronic
Signatures, Part 1: Hash Functions and Asymmetric
Algorithms", TS 102 176-1, July 2005.
[FIPS] National Institute of Standards and Technology, "Digital
Signature Standard (DSS)", FIPS PUB 186-2, December 1998.
[G] Goubin, L., "A Refined Power-Analysis-Attack on Elliptic
Curve Cryptosystems", Proceedings of Public-Key-
Cryptography - PKC 2003, Lecture Notes in Computer Science
2567, Springer Verlag, 2003.
[CFDA] Cohen, H., Frey, G., Doche, C., Avanzi, R., Lange, T.,
Nguyen, K., and F. Vercauteren, "Handbook of Elliptic and
Hyperelliptic Curve Cryptography", Chapman & Hall CRC
Press, 2006.
[HMV] Hankerson, D., Menezes, A., and S. Vanstone, "Guide to
Elliptic Curve Cryptography", Springer Verlag, 2004.
[HR] Huang, M. and W. Raskind, "Signature Calculus and the
Discrete Logarithm Problem for Elliptic Curves
(Preliminary Version)", Unpublished Preprint, 2006,
http://www-rcf.usc.edu/~mdhuang/mypapers/062806dl3.pdf.
[ISO1] International Organization for Standardization,
"Information Technology - Security Techniques - Digital
Signatures with Appendix - Part 3: Discrete Logarithm
Based Mechanisms", ISO/IEC 14888-3, 2006.
[ISO2] International Organization for Standardization,
"Information Technology - Security Techniques -
Cryptographic Techniques Based on Elliptic Curves - Part
2: Digital signatures", ISO/IEC 15946-2, 2002.
[ISO3] International Organization for Standardization,
"Information Technology - Security Techniques - Prime
Number Generation", ISO/IEC 18032, 2005.
[JMV] Jao, D., Miller, SD., and R. Venkatesan, "Ramanujan Graphs
and the Random Reducibility of Discrete Log on Isogenous
Elliptic Curves", IACR Cryptology ePrint Archive 2004/312,
2004.
[RFC3279] Bassham, L., Polk, W., and R. Housley, "Algorithms and
Identifiers for the Internet X.509 Public Key
Infrastructure Certificate and Certificate Revocation List
(CRL) Profile", RFC 3279, April 2002.
[RFC4050] Blake-Wilson, S., Karlinger, G., Kobayashi, T., and Y.
Wang, "Using the Elliptic Curve Signature Algorithm
(ECDSA) for XML Digital Signatures", RFC 4050, April 2005.
[RFC4492] Blake-Wilson, S., Bolyard, N., Gupta, V., Hawk, C., and B.
Moeller, "Elliptic Curve Cryptography (ECC) Cipher Suites
for Transport Layer Security (TLS)", RFC 4492, May 2006.
[RFC4754] Fu, D. and J. Solinas, "IKE and IKEv2 Authentication Using
the Elliptic Curve Digital Signature Algorithm (ECDSA)",
RFC 4754, January 2007.
[RFC5753] Turner, S. and D. Brown, "Use of Elliptic Curve
Cryptography (ECC) Algorithms in Cryptographic Message
Syntax (CMS)", RFC 5753, January 2010.
[SA] Satoh, T. and K. Araki, "Fermat Quotients and the
Polynomial Time Discrete Log Algorithm for Anomalous
Elliptic Curves", Commentarii Mathematici Universitatis
Sancti Pauli 47, 1998.
[SEC1] Certicom Research, "Elliptic Curve Cryptography",
Standards for Efficient Cryptography (SEC) 1, September
2000.
[SEC2] Certicom Research, "Recommended Elliptic Curve Domain
Parameters", Standards for Efficient Cryptography (SEC) 2,
September 2000.
[Sem] Semaev, I., "Evaluation of Discrete Logarithms on Some
Elliptic Curves", Mathematics of Computation 67, 1998.
[Sma] Smart, N., "The Discrete Logarithm Problem on Elliptic
Curves of Trace One", Journal of Cryptology 12, 1999.

[9] IETF RFC 6637 – Elliptic Curve Cryptography (ECC) in OpenPGP, 2012

8. References

[1] Harrington, D., Presuhn, R. and B. Wijnen, "An Architecture for
Describing SNMP Management Frameworks", RFC 2571, April 1999.
[2] Rose, M. and K. McCloghrie, "Structure and Identification of
Management Information for TCP/IP-based Internets", STD 16, RFC
1155, May 1990.
[3] Rose, M. and K. McCloghrie, "Concise MIB Definitions", STD 16,
RFC 1212, March 1991.
[4] Rose, M., "A Convention for Defining Traps for use with the
SNMP", RFC 1215, March 1991.
[5] McCloghrie, K., Perkins, D., Schoenwaelder, J., Case, J., Rose,
M. and S. Waldbusser, "Structure of Management Information
Version 2 (SMIv2)", STD 58, RFC 2578, April 1999.
[6] McCloghrie, K., Perkins, D., Schoenwaelder, J., Case, J., Rose,
M. and S. Waldbusser, "Textual Conventions for SMIv2", STD 58,
RFC 2579, April 1999.
[7] McCloghrie, K., Perkins, D., Schoenwaelder, J., Case, J., Rose,
M. and S. Waldbusser, "Conformance Statements for SMIv2", STD
58, RFC 2580, April 1999.
[8] Case, J., Fedor, M., Schoffstall, M. and J. Davin, "Simple
Network Management Protocol", STD 15, RFC 1157, May 1990.
[9] Case, J., McCloghrie, K., Rose, M. and S. Waldbusser,
"Introduction to Community-based SNMPv2", RFC 1901, January
1996.
[10] Case, J., McCloghrie, K., Rose, M. and S. Waldbusser, "Transport
Mappings for Version 2 of the Simple Network Management Protocol
(SNMPv2)", RFC 1906, January 1996.
[11] Case, J., Harrington D., Presuhn R. and B. Wijnen, "Message
Processing and Dispatching for the Simple Network Management
Protocol (SNMP)", RFC 2572, January 1998.
[12] Blumenthal, U. and B. Wijnen, "User-based Security Model (USM)
for version 3 of the Simple Network Management Protocol
(SNMPv3)", RFC 2574, January 1998.
[13] Case, J., McCloghrie, K., Rose, M. and S. Waldbusser, "Protocol
Operations for Version 2 of the Simple Network Management
Protocol (SNMPv2)", RFC 1905, January 1996.
[14] Levi, D., Meyer, P. and B. Stewart, "SMPv3 Applications", RFC
2573, January 1998.
[15] Wijnen, B., Presuhn, R. and K. McCloghrie, "View-based Access
Control Model (VACM) for the Simple Network Management Protocol
(SNMP)", RFC 2575, January 1998.
[16] Bradner, S., "Key words for use in RFCs to Indicate Requirements
Levels", BCP 14, RFC 2119, March 1997.
[17] McCloghrie, K. and M. Rose, "Management Information Base for
Network Management of TCP/IP-based internets - MIB-II", STD 17.
RFC 1213, March 1991.
[18] Postel, J., "Internet Protocol", STD 5, RFC 791, September 1981.
[19] McCloghrie, K., "Extensions to the Generic-Interface MIB", RFC
1229, May 1991.
[20] ATM Forum Technical Committee, "LAN Emulation Client Management:
Version 1.0 Specification", af-lane-0044.000, ATM Forum,
September 1995.
[21] Stewart, B., "Definitions of Managed Objects for Character
Stream Devices using SMIv2", RFC 1658, July 1994.
[22] Case, J., Mundy, R., Partain, D. and B. Stewart, "Introduction
to Version 3 of the Internet-standard Network Management
Framework", RFC 2570, April 1999.
[23] McCloghrie, K. and F. Kastenholz, "Evolution of the Interfaces
Group of MIB-II", RFC 1573, January 1994.
[24] McCloghrie, K. and F. Kastenholz, "The Interfaces Group MIB
using SMIv2", RFC 2233, November 1997.

ChatGPT

自動車関連のセキュリティ技術について、https://www.autosar.org/fileadmin/standards/R24-11/CP/AUTOSAR_CP_SWS_CryptoServiceManager.pdf の文書およびその参考文献から、抜け漏れをさがしてください。

思考時間: 40s
いいですね — ご指定の AUTOSAR 「Specification of Crypto Service Manager (CSM)」R24-11(PDF)とその本文・参考文献を読み込み、**その文書(+文中で参照されている文献)に対する「抜け/不足(ギャップ)」をベストエフォートで洗い出しました。以下は私が文書全体(319ページ)をスキャンして検出した主要な抜け・改善ポイントと、根拠(該当PDF位置)および外部標準・最近の論点への参照です。まず要点、そのあと詳しいギャップ一覧→優先度付き改善案の順で示します。
要点(短く)
CSM仕様は暗号API/ジョブ/鍵管理の機能を詳細に定義する一方で、実運用で重要な「ライフサイクル管理」「ガバナンス」「規制適合」「ハードウェア信頼アンカー/HSM連携」「量子耐性(PQC)」などの横断的・運用的項目が明示的にカバーされていない/薄い箇所が複数あります。
AUTOSAR
文書自身が「CSMにユーザ管理はない」と明記している(=アクセス制御は上位で対応すべき)ため、鍵アクセス制御や認可・認証の責務分離が曖昧で、そのままでは規制(UNECE/ISO等)対応や監査に不利です。
AUTOSAR
最近の業界要請(UNECE R155/R156、ISO/SAE 21434、PQC、HSMの普及)との整合性確認・追記が必要です(下で個別に証拠と提案あり)。
ISO+2
newtec.de+2
参照したソース(主要)
AUTOSAR — Specification of Crypto Service Manager, AUTOSAR CP R24-11 (PDF)。全文を確認しました(319ページ)。
AUTOSAR
ISO/SAE 21434(自動車サイバーセキュリティ標準:ライフサイクル/TARA等)。
ISO
UNECE R155 / R156(車両レベルのCSMS と ソフトウェア更新管理)。
newtec.de+1
Post-Quantum / PQC に関する自動車分野の最近の議論(業界記事/論文)。
Apriorit+1
AUTOSAR の Secure Hardware Extensions(SHE)・HSM関連ドキュメント(参照推奨)。
AUTOSAR+1
(以降、各指摘に該当PDFの位置を明示します)
詳細:検出した「抜け/不足」一覧(優先度付き、根拠付き)
優先度:高(実務・法規対応上まず対応すべき)
規制・標準(ISO/SAE 21434、UNECE R155/R156)への明確な整合性/トレースがない
根拠:CSM文書の「Related documentation」項目は主に AUTOSAR 内部文書といくつかのRFC(例:RFC5639, RFC6637)を列挙していますが、ISO/SAE 21434 や UNECE 規則(R155/R156)そのものへの参照や、CSM がそれらの要求にどう応えるかのマッピングが見当たりません(文書目次/関連文献一覧参照)。
AUTOSAR
影響:車両認証(型式承認)や CSMS 要件対応のため、CSM の仕様がどう運用上(ライフサイクル・TARA・証跡)貢献するか明示する必要があります。外部規制に適合させる手順が無いと監査で指摘される可能性が高い。
ISO+1
鍵のライフサイクル管理(プロビジョニング、ローテーション、引退、バックアップ、復元、失効)に関する運用手順・インタフェースが不足
根拠:CSM は「Key Management Interface」等を定義しますが、実運用(製造時の注入、フィールド更新/リプロビジョニング、失効証跡、鍵復旧)の具体的プロセスや外部サービスとの連携仕様が弱い(仕様内に“KeySetInvalid/KeyGetStatus”等はあるが、ライフサイクル管理の運用フローや管理/監査ログ要件は限定的)。
AUTOSAR
影響:供給連鎖(OEM↔サプライヤ)での鍵注入やリプロビジョンの実務ルール、証跡保持が欠けるとセキュリティ管理に穴ができる。
ハードウェア・トラストアンカー(HSM/SHE)との統合仕様が抽象的で、ベンダー実装差が大きくなる恐れ
根拠:文書は「Crypto Driver が SHA-1, RSA, AES 等を提供する」と明記(=暗号ルーチンはドライバ/ライブラリへ委任)する一方で、HSM 固有の機能(セキュアブート根拠、鍵の物理境界、対改ざんロギング、鍵操作の証明付き実行/attestation)に関する具体的インタフェースや要求が明示されていません。
AUTOSAR+1
影響:HSM を使う実装で OEM 間・サプライヤ間の互換性が取れない。NDA下のベンダ機能に依存すると監査/評価で差が出る。
優先度:中(近未来の脅威・評価で必要)
量子耐性(Post-Quantum Cryptography, PQC)・アルゴリズムアジリティの扱いがない/限定的
根拠:文書中に「quantum」「post-quantum」といった語は見当たらず、NIST/NIST候補やPQC移行計画に関する参照が無い(見つからない)。現在、自動車セキュリティでは長期の鍵保持やOTAでの鍵交換を考えるとPQC方針が重要になっています。
AUTOSAR+1
影響:将来の量子脅威に備えた移行方針・アルゴリズム選定・ハイブリッド鍵交換などの設計指針が無いと、将来的な脆弱化対応に時間がかかる。
テレメトリ/監査ログ/セキュリティイベントの取り扱い(証跡、フォレンジクス、インシデント対応)に関する仕様が薄い
根拠:文書に「Security Events」や「Production Errors」の章はありますが、どのレベルで何をログするか(鍵操作ログ、ジョブ実行ログ、失敗時の証跡)、ログ保護・プライバシー・転送(車外に出す場合の保護)までの詳細は限定的です。
AUTOSAR
影響:UNECE/21434 等のインシデント管理・監査証跡要件に照らすと補強が必要。
優先度:中〜低(設計品質・防御深度)
サイドチャネル/物理攻撃対策(タイミング攻撃、電磁、故意な故障注入)に対する設計指針がない
根拠:CSM は API・ジョブの仕様に重心がありますが、物理側チャネルへの対策設計(HSMのTI対応、マスク、検出ロジック等)に関する要求は基本的にCrypto DriverやSecure Hardware の別ドキュメント頼みになっている。
AUTOSAR+1
証明書管理(PKI)やX.509のライフサイクル/フォーマット互換性・失効(CRL/OCSP)などに関する統合仕様が縮減されている点
根拠:履歴に「certificate functionalityを KeyM に移動」との記載があり(=CSMから切り出し)、CSM自身での証明書フルマネージメントの言及は限定されています。結果として証明書を使うユースケースでのAPI・運用文書が分散しています。
AUTOSAR
サプライチェーン(SBOM、プロビジョニングチェーン、製造/工場注入ワークフロー)とCSM の関連仕様が薄い
根拠:CSMは基本ソフトモジュールの仕様であり、SBOMやプロビジョニング運用までは扱っていません(その分野は別ガイダンス必要)。
AUTOSAR
評価・認証(FIPS/CC/PSA/車載 HSM 認証)マッピングが無い
根拠:仕様に「アルゴリズム群」「ジョブ」「エラー分類」はあるが、実装をどのような外部評価基準(FIPS 140、Common Criteria、PSA Certified)に合わせるかのマッピングは無い。これがあるとベンダ実装の適合審査が容易になる。
AUTOSAR
優先度付き改善提案(具体的・実務で使える形で)
A. すぐに入れる(必須)
規格対応セクションの追加(「CSM and Standards Mapping」)
目的:CSM の各機能(鍵管理、ジョブ、ログ、インタフェース)を ISO/SAE 21434、UNECE R155/156、(必要なら)WP.29 規則にマッピングする表を追加。監査での説明責任をクリアにする。参考:ISO/SAE 21434 概要。
ISO+1
鍵ライフサイクル運用フローの標準化ドキュメント(付録または別章)
含むもの:製造時注入、在庫鍵管理、鍵ローテーション手順、失効/復旧手順(誰が・どのシステムで実行するか)、ログ要件(なにを・どの粒度で記録するか)およびAPI拡張案。
AUTOSAR
HSM/SHE 連携仕様の拡張
具体策:HSM が提供する attestation API、鍵操作の物理境界保証、鍵の永続格納形式、鍵操作の非可逆ログ(audit trail)などを CSM-CryptoDriver 間で標準化する。AUTOSAR の Secure Hardware Extensions を参照してインタフェースを具体化。
AUTOSAR+1
B. 中期(戦略的)
PQC 対応方針(アルゴリズムアジリティ)を追加
具体策:将来鍵・鍵交換アルゴリズムに対する「アルゴリズムID」「ハイブリッド鍵交換」サポート方針、PQC の実装ガイドライン、影響を受けるジョブ(署名、鍵交換、KDF)を列挙する。参考に自動車向けPQ議論資料。
Apriorit+1
証跡/監査ログ仕様の強化
何を追加:鍵の作成/削除/失効/注入/ローテーション操作ログ、ジョブ失敗時のエビデンス、ログの保護(整合性・機密性)、外部転送ルール(プライバシー配慮)等。
AUTOSAR
インシデント対応トリガー・イベント定義
何を:CSM に関係するインシデント(鍵漏洩疑い、HSM耐障害、無効化指示など)発生時のインタフェース(誰に通知、どのモジュールがロールバックを指示するか)を定義しておく。
C. 低〜補完(品質向上)
サイドチャネル耐性に関する最低仕様(Crypto Driver 側への要件)
例:タイミング変動マスキング、定数時間演算オプション、故障注入検出 PINs の検討。
AUTOSAR
評価/認証マトリクスの例示
例:実装が「FIPS 140-2 レベルX」「Common Criteria EAL Y」「PSA level Z」を満たすための推奨実装パターンを付録に載せる。
具体的に「どこ(PDFの箇所)」に追記すべきか(推奨箇所)
「3 Related documentation」章:外部規格(ISO/SAE 21434、UNECE R155/R156、NIST PQC進捗)を追加し、ドキュメントごとの期待役割(CSMが担う範囲・外部で担う範囲)を明示。
AUTOSAR+1
「4.3 Security Implications」:現状“ユーザ管理はない”とある箇所(CSM はアクセス制御を担わない)に続けて“しかしながら監査・法規対応のため以下の実運用要件を満たすこと”という追記(鍵ログ、認可境界、プロビジョニング手順の参照)を推奨。
AUTOSAR
「7.2.2.3 Key Management」節:鍵ライフサイクル詳細フロー、Factory / Field / Decommission の各ケースごとの操作手順を追加。
AUTOSAR
「8 API specification」付録:HSM/attestation API、PQCアルゴリズムID の拡張案、監査ログ API を追加(後方互換性を保つ形)。
AUTOSAR
なぜこれが重要か(簡潔に)
自動車は長寿命製品であり、鍵と証明書は車両寿命を通じて保護し続ける必要があります(→ライフサイクル管理とPQCが重要)。
DNB https://d-nb.info/1199614254/34?utm_source=chatgpt.com
UNECE や ISO の規格・規制は既に導入されており、型式認証やCSMS要求は現実的な要請です。仕様はこれらと実務的につながるようにガイドラインを追加するべきです。
newtec.de+1 https://www.newtec.de/en/knowledge/unece-r-155-and-unece-r-156-cybersecurity-of-motor-vehicles/?utm_source=chatgpt.com
次の具体的作業(私がすぐできること)
(希望があればこちらを作成します。全部この場で作成可能です)
ギャップマトリクス(Excel/表):CSMの各節 ↔ 必須運用/規格要件(ISO21434, UNECE R155, PQC, HSM要件) — 欠落/部分実装/満足の3段階で評価。
追記ドラフト(章単位):上で示した「Key lifecycle」「HSM integration」「PQC方針」「ログ/監査」について、CSM に差し込める
原文レベルの追記案(英語)**を作る。
API 拡張案:HSM attestation / audit-log / PQC アルゴID を含む C API スケルトン(ヘッダ・構造体)を作成。
やる場合はどれを優先するか教えてください(最優先案をそのまま作成して提示します)。
注:今回行った「ギャップ検出」は文書本文と参照リストの読み取りに基づく技術的レビューです。必要なら該当PDF中の具体ページ(例:Security Implications の該当ページ番号など)をさらに明示して参照箇所をピンポイントで示します。
参考(本文中で引用した主要箇所)
AUTOSAR CP R24-11 — Specification of Crypto Service Manager(全文、R24-11、319ページ)。(文書内「3 Related documentation」「4.3 Security Implications」「7.2.2.3 Key Management」等を参照して評価実施)。
AUTOSAR https://www.autosar.org/fileadmin/standards/R24-11/CP/AUTOSAR_CP_SWS_CryptoServiceManager.pdf
ISO/SAE 21434(自動車サイバーセキュリティ標準)。
ISO https://www.iso.org/standard/70918.html?utm_source=chatgpt.com
UNECE R155 / R156(車載サイバーセキュリティ管理・ソフト更新管理)。
newtec.de+1 https://www.newtec.de/en/knowledge/unece-r-155-and-unece-r-156-cybersecurity-of-motor-vehicles/?utm_source=chatgpt.com
Post-Quantum Cryptography in Automotive(業界記事/論文の最近の議論)。
Apriorit+1 https://www.apriorit.com/dev-blog/post-quantum-cryptography-in-automotive?utm_source=chatgpt.com
AUTOSAR TR: Secure Hardware Extensions(SHE) — HSM/SHE の設計指針として参照推奨。
AUTOSAR https://www.autosar.org/fileadmin/standards/R22-11/FO/AUTOSAR_TR_SecureHardwareExtensions.pdf?utm_source=chatgpt.com
必要でしたら次は私がすぐに(この返信の続きとして)以下を作成します(どれでも可能です):
ギャップマトリクス(表形式)を 完全版 で作成(CSV/表で提示)
CSM へ挿入可能な 英語ドラフト文(章/節分)(差分形式)
HSM/attestation と PQC を含む API 追加案(C ヘッダ+説明)
どれを先に作りましょうか?(ご指定が無ければ、まず「ギャップマトリクス(表)」を作ります)

AUTOSAR CSM — ギャップマトリクス(完全版)、英語ドラフト挿入案、API追加案

以下は、ご指定の順(1. ギャップマトリクス、2. CSM に差し込める英語ドラフト、3. API 追加案(Cヘッダ+説明))でまとめたドキュメントです。AUTOSAR CSM(R24-11)にそのまま差し込める/参考にできる形で作成しています。

1) ギャップマトリクス(CSM節 ⇔ 外部要件/運用要件)

説明:右の列は「現状の仕様での充足レベル(S: 満足 / P: 部分 / N: 不足)」、次に推奨対応(短め)と優先度を示します。

CSMの節(参照) 要求・期待される外部基準/運用要件 充足度 観察されたギャップ(要約) 推奨対応(短) 優先度
Related documentation(3.x) ISO/SAE 21434, UNECE R155/R156, WP.29 要求 N 外部規格とのマッピング無し 「Standards Mapping」章を追加
Security Implications(4.3) 監査/証跡/認可の明確化 P "CSMはユーザ管理しない"と明記されるが、監査要件の役割分担が曖昧 監査ログ・証跡要件の追記
Key Management(7.2.2.3 等) 鍵のライフサイクル(注入/ローテーション/失効/復旧/バックアップ) P API で Key操作はあるが実運用フロー・プロトコルが不足 ライフサイクル手順とAPI拡張を追加
Crypto Driver インタフェース HSM/SHE の attestation, secure storage, key-boundary P HSM固有機能(attestation等)を標準化していない HSM attestation API, key origin metadata を追加
Algorithm spec / Supported algorithms PQC / アルゴリズムアジリティ N PQC・ハイブリッドを扱う方針が無い PQC移行方針とアルゴリズムID体系を定義
Logging / Audit 証跡の粒度、保護、外部転送ルール P ログ項目・保護・滅失対応が限定的 ログ仕様(what/when/who)と保護(HMAC/署名)を追加
Certificate handling (PKI) CRL/OCSP, 証明書失効、フォーマット互換 P 証明書管理が分散している 証明書運用フローの参照と統合ガイダンス
Incident response インシデントのトリガー定義・通知経路 N インシデント種別とCSMの役割が定義されていない インシデントインタフェース(通知/ロック/失効)を追加
Side-channel / Fault injection 実装側での物理攻撃対策要件 N CSM仕様内の明示要件がない(Crypto Driver任せ) 最低限の非機密演算要件を規定(定時処理等)
Evaluation / Certification mapping FIPS/CC/PSA 対応目標 N 実装適合性の比較軸がない 推奨マトリクスの付録化
Supply chain / Provisioning workflow 製造→フィールドの鍵注入とSBOM N 製造時注入・プロビジョニングフローの記述がない 製造/工場注入のテンプレ手順を追加

2) CSM に差し込める英語ドラフト(章/節単位)

以下は原文レベルで差し込めるドラフト文です。必要に応じて用語("CryptoServiceManager" など)は原文の命名に合わせて置換してください。

A. New section: "CSM — Mapping to External Standards"

## X. Mapping to External Standards

This section provides an explicit mapping between the functionalities defined in this Crypto Service Manager (CSM) specification and relevant external standards and regulations. The goal is to clarify responsibilities, support auditability, and assist implementers in achieving compliance with regulatory and industry requirements.

X.1 Standards covered
- ISO/SAE 21434: Road vehicles — Cybersecurity engineering
- UNECE R155 / R156 (WP.29): Requirements for Cyber Security Management System (CSMS) and Software Update Management System (SUMS)
- NIST publications relevant to cryptography and PQC transition
- Other regional or market-specific regulations (to be declared by the product OEM)

X.2 Mapping matrix (high-level)
For each CSM capability (Key Management, Crypto Jobs, APIs, Logging, HSM integration), a mapping to the related clause(s) of the above standards is provided in Appendix Y (Mapping Matrix). Implementers should use this mapping to inform design choices, evidence collection, and operational procedures for certification and audits.

X.3 Responsibility and boundary
This document defines the functional boundary of the CSM. Responsibilities for access control, organizational policy, or system-level incident response remain with higher-level management systems (e.g., CSMS) and are outside the direct scope of the CSM. Nevertheless, CSM implements MUST provide traceable interfaces and logs enabling CSMS-level functions to perform their duties.

B. Appendix/Section: "Key Lifecycle Management (Factory and Field)"

## Y. Key Lifecycle Management (Factory and Field)

Y.1 Overview
This section defines standard operational procedures for cryptographic key lifecycle management covering: generation, provisioning (factory), activation, rotation, backup, recovery, revocation, and archival/destruction. It also defines required metadata and evidence that the CSM must expose.

Y.2 Key metadata
Each key managed by the CSM MUST be associated with the following metadata:
- KeyIdentifier (unique)
- KeyType (Symmetric / Asymmetric)
- Origin (FactoryInjected | GeneratedInVehicle | Imported) 
- ProtectionLevel (PlaintextAllowed | EncryptedAtRest | HSMProtected)
- ValidFrom / ValidTo
- UsagePolicy (signing | encryption | KDF | storage)
- AuditFlags (recordCreation | recordUsage | recordExport)

Y.3 Factory provisioning
- Factory provisioning MUST be executed via a secure, auditable channel. The provisioning flow SHALL include:
  1. Provisioning policy validation
  2. Authenticating provisioning entity (mutual authentication)
  3. Sealed injection (if HSM present) or encrypted transport
  4. Receipt and non-repudiable audit record creation
- CSM API: Key_ImportWithOrigin(KeyBlob, KeyMetadata, ProvisioningEvidence)

Y.4 Rotation and expiry
- Key rotation MUST be supported and performed according to UsagePolicy and ValidTo.
- Rotation operations MUST create an immutable audit record including the triggering entity and time.
- CSM API: Key_Rotate(KeyIdentifier, NewKeySpec, RotationEvidence)

Y.5 Revocation and compromise handling
- On suspected compromise, CSM SHALL allow immediate revocation of affected keys and must support broadcasting revocation to dependent modules.
- CSM SHALL support revocation reasons and timestamped evidence.
- CSM API: Key_Revoke(KeyIdentifier, ReasonCode, Evidence)

Y.6 Backup and recovery
- Backup of any key material that leaves the HSM boundary SHALL be encrypted and authorized by a multi-party control (e.g., split knowledge).
- Recovery operations SHALL be logged with multi-party endorsement.

Y.7 Audit and evidence
- All lifecycle operations MUST produce signed audit records (see Audit Log section). Audit records SHALL include KeyIdentifier, operation, actor, timestamp, and outcome.

C. Section: "HSM Integration and Attestation"

## Z. HSM Integration and Remote Attestation

Z.1 Purpose
To provide a consistent set of interfaces between the CSM and secure hardware (HSM, Secure Element, or SHE) enabling implementers to rely on hardware-provided protection primitives while retaining interoperability across vendor implementations.

Z.2 Required capabilities of underlying secure hardware
- Secure key storage with non-exportability for protected keys
- Cryptographic primitive implementations (AES, RSA, ECC, SHA, KDFs)
- Remote/Local attestation capability to assert firmware/boot state, key origin, and HSM configuration
- Secure lifecycle operations (secure key generation, secure erase)
- Tamper detection / secure debug controls

Z.3 Attestation interface (concept)
- CSM SHALL be able to request an attestation token from the HSM describing the current security state. The attestation token SHALL be signed by the HSM's device key and include:
  - HSM identifier
  - Firmware version
  - Secure boot state
  - Keys (or KeyIdentifiers) present and their origin (if supported)
  - Measured boot PCR values (if supported)
- CSM API: Hsm_RequestAttestation(AttestationOptions) -> AttestationToken

Z.4 Key origin and binding
- When keys are provisioned into the vehicle, the CSM MUST tag keys with origin metadata and whether they are HSM-bound (non-exportable).

Z.5 Failure modes
- If attestation fails or device indicates tamper, CSM SHALL refuse to perform operations that require protected keys and SHALL emit an incident event.

D. Section: "Audit Log and Forensics Support"

## W. Audit Log and Forensics Support

W.1 Objectives
Provide consistent, tamper-evident audit records for cryptographic operations necessary for compliance, incident response, and forensic analysis.

W.2 Required audit record fields
- EventID
- EventType (KeyCreate, KeyImport, KeyDelete, KeyRotate, CryptoOp, HSMAttest, AttestFail, Revoke)
- KeyIdentifier (if applicable)
- Actor (ComponentID, authenticated entity)
- Timestamp (ISO8601 with timezone)
- Outcome (Success/Failure/ErrorCode)
- CorrelationID (to link related events)
- EvidenceBlob (optional: signed attestation token, provisioning receipt)

W.3 Protection
- Audit records SHALL be protected for integrity (signed or HMAC) and SHALL support chained log signing to provide tamper-evidence.
- If logs are transferred off-vehicle, transport SHALL be authenticated and logs SHALL be encrypted in transit.

W.4 Retention and export
- Retention period and export policy SHALL be defined by OEM/CSMS. CSM SHALL support on-demand export of events, with filters and pagination.
- CSM API: Audit_Export(filter, destination, authorization) -> ExportReceipt

3) API 追加案(C ヘッダ+説明)

以下は C 言語ヘッダとして追加できる宣言の例です。命名規約は AUTOSAR の既存スタイル(大文字スネーク等)に合わせて調整してください。

/* csm_extensions.h -- Suggested C API extensions for HSM attestation, key lifecycle and audit export */

#ifndef CSM_EXTENSIONS_H
#define CSM_EXTENSIONS_H

#include <stdint.h>
#include <stddef.h>

/* Basic types */
typedef uint32_t CsmReturnType;
#define CSM_OK 0
#define CSM_ERROR_GENERIC 1
#define CSM_ERROR_AUTH 2
#define CSM_ERROR_NOT_FOUND 3
#define CSM_ERROR_INVALID_ARG 4

/* Key identifier */
typedef struct { uint8_t id[16]; } CsmKeyId_t; /* 128-bit compact ID */

/* Key metadata structure */
typedef struct {
    CsmKeyId_t keyId;
    uint8_t keyType; /* 0=symmetric,1=asymmetric */
    uint8_t origin;  /* 0=FactoryInjected,1=GeneratedInVehicle,2=Imported */
    uint8_t protectionLevel; /* 0=Plain,1=EncryptedAtRest,2=HSMProtected */
    uint64_t validFrom; /* epoch */
    uint64_t validTo;   /* epoch */
} CsmKeyMetadata_t;

/* Attestation token (opaque blob returned by HSM) */
typedef struct {
    uint8_t *data;    /* pointer to DER/CBOR blob */
    size_t   length;
} CsmAttestationToken_t;

/* Audit record filter */
typedef struct {
    uint64_t since; /* epoch */
    uint64_t until; /* epoch */
    uint8_t  eventMask; /* bitmask of event types */
} CsmAuditFilter_t;

/* Function: Request attestation from underlying secure hardware */
CsmReturnType Csm_HsmRequestAttestation(const uint8_t options, CsmAttestationToken_t *token_out);

/* Function: Import key with origin metadata and provisioning evidence */
CsmReturnType Csm_KeyImportWithOrigin(const uint8_t *keyBlob, size_t blobLen, const CsmKeyMetadata_t *meta, const uint8_t *provEvidence, size_t provEvidenceLen, CsmKeyId_t *outKeyId);

/* Function: Rotate key */
CsmReturnType Csm_KeyRotate(const CsmKeyId_t *oldKeyId, const uint8_t *newKeySpec, size_t specLen, const uint8_t *rotationEvidence, size_t evidenceLen, CsmKeyId_t *outNewKeyId);

/* Function: Revoke key */
CsmReturnType Csm_KeyRevoke(const CsmKeyId_t *keyId, const uint8_t reasonCode, const uint8_t *evidence, size_t evidenceLen);

/* Function: Export audit logs with filter and target (opaque dest) */
CsmReturnType Csm_AuditExport(const CsmAuditFilter_t *filter, const uint8_t *destination, size_t destLen, uint8_t *exportReceipt, size_t *receiptLen);

/* Function: Query audit log count matching filter */
CsmReturnType Csm_AuditCount(const CsmAuditFilter_t *filter, uint32_t *count_out);

#endif /* CSM_EXTENSIONS_H */

実装に関する注記

  • Csm_HsmRequestAttestation は HSM 特有の表現(DER/CBOR)を返すため、呼び出し側で検証/解釈する必要があります(公開鍵基盤により検証)。
  • KeyImportWithOrigin は工場注入や外部プロバイダからの鍵導入に使い、provEvidence で注入された証跡(署名済みの provisioning receipt)を受け取ります。
  • 監査ログはチェーン署名(chained log signing)や HMAC で保護することを強く推奨します。転送時は TLS+相互認証を利用してください。

付録:作業履歴・出典(簡潔)

  • AUTOSAR: "Specification of Crypto Service Manager" R24-11 — 本文参照(CSMの節番号に対応)。
  • ISO/SAE 21434, UNECE R155/R156, NIST PQC ドキュメント — ギャップ検出の観点で参照(規格整合のため)。

以上です。文書はそのままコピー&ペーストで AUTOSAR 文書の差分と

0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?