Skip to content

docs: cryptography fix, refactor and refer to draft#4933

Open
romshark wants to merge 12 commits into
scionproto:masterfrom
romshark:docs-cryptography-fix-and-refer-to-draft
Open

docs: cryptography fix, refactor and refer to draft#4933
romshark wants to merge 12 commits into
scionproto:masterfrom
romshark:docs-cryptography-fix-and-refer-to-draft

Conversation

@romshark

@romshark romshark commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

Instead of duplicating info on doc pages - simplify and refer to IETF drafts; specifically HTML in the latest version (currently 13: https://www.ietf.org/archive/id/draft-dekater-scion-pki-13.html)

Docs are giving a big picture introduction and leave the details to the actual spec.

This also fixes incorrect docs:

  • Regular voting cert validity: align with the draft (1y -> 5y).
  • Sensitive voting cert: "5 year" -> "5 years" wording.
  • Docs copyright: bump to 2026.

@romshark romshark self-assigned this Jun 8, 2026
@romshark romshark marked this pull request as ready for review June 15, 2026 11:46
@romshark romshark requested review from a team and oncilla June 15, 2026 14:43
Comment thread doc/cryptography/certificates.rst Outdated
Comment thread doc/cryptography/certificates.rst Outdated
@romshark romshark force-pushed the docs-cryptography-fix-and-refer-to-draft branch from 2840b6a to f8572ad Compare June 15, 2026 18:26
@romshark romshark requested a review from tzaeschke June 15, 2026 18:51

@tzaeschke tzaeschke left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we need to clarify what the intention of this document is.

I think the intention should be to give the reader a good understanding of how it works. The details can be left to the spec.

Currently the document seems a bit confused, some things are mentioned multiple times, e.g. sensitive vs regular updates and that the former concern policy and quorum). Other things are not mentioned at all anymore, like who is actually voting on these updates and what quorum and policy mean.

Basically, I would keep most of the text and remove only normative language and code blocks.

Comment thread doc/cryptography/certificates.rst Outdated
Comment thread doc/cryptography/certificates.rst Outdated
Comment thread doc/cryptography/certificates.rst
All constraints in :ref:`general-certificate-requirements` apply to **CP Root Certificates**.
**CP Root Certificates** state which ASes are CA ASes for an ISD. They are
self-signed CA certificates owned by CA ASes, and are embedded in TRCs to
bootstrap trust (see the :doc:`TRC Specification <trc>`). Their full profile —

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove "-"?

(``issuer`` and ``subject`` are the same entity). They are owned by CA ASes.

**CP CA Certificates** are signed by **CP Root Certificates**.
**CP CA Certificates** are used by CA ASes to sign **CP AS Certificates**. They

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove "-"?
Also, this paragraph seems like an exact copy of the previous section (replacing some keywords only).

Comment thread doc/cryptography/trc.rst
AttributeValue ::= ANY

SignatureValue ::= OCTET STRING
=================

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
=================
=================
-----------------

Not sure this should be a new Chapter?

Comment thread doc/cryptography/trc.rst
are specified in `Certification Path — Trust Anchor Pool
<https://www.ietf.org/archive/id/draft-dekater-scion-pki-13.html#name-certification-path-trust-an>`_.

Voting Certificate

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This section doesn't appear to contain any(much) new information, maybe merge it with TRC Update above?

Comment thread doc/cryptography/trc.rst
implies, that the signer infos can be reordered without affecting verification.

**Two TRCs are equal, if and only if their payloads are byte equal.**
Two TRCs are equal if and only if their payloads are byte-equal; this is sufficient

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This section doesn't explain why equality is relevant and discussed here. Maybe just keep the old text?

Comment thread doc/cryptography/trc.rst
votes are cast by a **Sensitive Voting Certificate**. In both cases, the relying
party checks that all signatures are verifiable, and no superfluous signatures
are attached.
A TRC update is either a **regular update** (routine re-issuance with unchanged

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should keep the text about base numbers increments etc. This is important for the understanding how this works.

Comment thread doc/cryptography/trc.rst
.. _trc-format:

TRC Format
==========

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think much of the text in this section is actually useful, e.g. explaining authorative ASes, Voting ASes, core ASes. See my general comment.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1, I think here it could be useful to add figure 1 or 2 from the PKI draft, since it gives the reader a quick overview

@nicorusti

nicorusti commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

Cryptography:

In the main page (Cryptography), have a brief paragraph explaining the purpose of it and scionproto's relation to the draft, something like:

SCION's control plane messages and path information are all authenticated. The verification of messages relies on the control-plane PKI or CP-PKI. It consists of a set of mechanisms, roles, and policies related to the management and usage of certificates, which enables the verification of signatures of, e.g., path-segment construction beacons (PCBs).
This implementation follows the SCION PKI specification in [IETF draft]

Certificate Specification

  • I think this page could be shrank a lot. It could just give an overview of each certificate type, and mention that there are additional constraints and extensions that are required, with a reference to the draft.
  • Subsections could only mention more implementation-focused details, that are sometimes not in the draft (e.g. the OIDs for the supported algorithms0

TRC

  • I think an overview picture here would be helpful, you could use figure 1 or 2 from the draft. Then you could briefly explain the role of various certificates contained in the TRC

Leaving more comments on the change directly


This document contains the specification for **Control Plane (CP) Root
Certificates**, **CP CA Certificates** and **CP AS Certificates**.
SCION uses three types of X.509 v3 **Control Plane (CP) certificates** that build

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Four, there are also Voting Certificates.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Additionally, SCION uses two **voting certificates** - the *sensitive voting
certificate* and the *regular voting certificate* - which carry the keys that
cast votes in the TRC update process (see the :doc:`TRC Specification <trc>`).

How about appending that after the list of CP certs?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've applied this for now, but let me know whether it's good.

Comment thread doc/cryptography/certificates.rst Outdated
- **CP Root Certificate** — a self-signed CA certificate, owned by a CA AS and
embedded in a TRC, that signals which ASes may act as certificate authorities in
an ISD.
- **CP CA Certificate** — used by a CA AS to sign CP AS certificates.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IN the draft, we call them Issuing CA certificates. Not sure if you wan to align or not

Comment thread doc/cryptography/certificates.rst Outdated
Comment thread doc/cryptography/certificates.rst Outdated

.. _cp-root-certificate:

CP Root Certificate

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe this paragraph could go in the bullets in the introduction?

(same for CP CA Certificate and CP AS Certificate)

Comment thread doc/cryptography/certificates.rst Outdated
Certificate
<https://www.ietf.org/archive/id/draft-dekater-scion-pki-13.html#name-control-plane-root-certific>`_.

The recommended maximum validity period of a **CP Root certificate** is 1 year.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe in the intro you could mention that PKI relies on short-lived certificates, and that the recommended max validity is in the draft Table 2: Certificates

Comment thread doc/cryptography/interactions.rst Outdated
verifiable at time of use. We cannot simply rely on them being verified on
insert, since TRC updates that change the root key can invalidate a certificate
chain.
Most SCION control-plane messages (for example, each AS's hop information in a path

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Most SCION control-plane messages .. are signed

I think they are all signed

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment on lines +74 to +76
Cryptographic Material
<https://scionassociation.github.io/scion-cp_I-D/draft-dekater-scion-controlplane.html#name-distribution-of-cryptograph>`_.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is also another section: 2.5. Renewal of Cryptographic Material

Query: ISD
Response: ISD, serial number, base number, signature

The requester asks what the latest TRC for a given ISD known to the requestee

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think all the text below could be removed, and you could have just a little bit of text above explaining key interactions, then pointing to the spec for the RPCs.

Comment thread doc/cryptography/trc.rst
Comment on lines +22 to +25
The TRC payload is a DER-encoded container holding the ISD's policy fields and the
set of self-signed certificates that anchor trust for the ISD. Its schema, fields
and the constraints on the certificate set are specified in `TRC Fields
<https://www.ietf.org/archive/id/draft-dekater-scion-pki-13.html#name-trc-fields>`_.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would specifically link its fields, but also its ASN.1 module in the appendix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants