summaryrefslogtreecommitdiff
path: root/src/tag.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/tag.rs')
-rw-r--r--src/tag.rs23
1 files changed, 5 insertions, 18 deletions
diff --git a/src/tag.rs b/src/tag.rs
index b50f5f5..4e3a8f1 100644
--- a/src/tag.rs
+++ b/src/tag.rs
@@ -4,26 +4,13 @@
pub enum Tag {
// Enforcement of the "tags in strictly increasing order" rule is done using the
// little-endian encoding of the ASCII tag value; e.g. 'SIG\x00' is 0x00474953 and
- // 'NONC' is 0x434e4f4e. The tags are listed here is reverse lexical order which
- // matches the little-endian comparison order.
- SREP,
- SIG,
- ROOT,
- RADI,
- PUBK,
- PATH,
- PAD,
- NONC,
- MINT,
- MIDP,
- MAXT,
- INDX,
- DELE,
- CERT,
+ // 'NONC' is 0x434e4f4e.
+
+ SIG, NONC, DELE, PATH, RADI, PUBK, MIDP, SREP, MINT, ROOT, CERT, MAXT, INDX, PAD
}
-static PAD_VALUE: [u8; 4] = [b'P', b'A', b'D', 0x00];
-static SIG_VALUE: [u8; 4] = [b'S', b'I', b'G', 0xff];
+static PAD_VALUE: [u8; 4] = [b'P', b'A', b'D', 0xff];
+static SIG_VALUE: [u8; 4] = [b'S', b'I', b'G', 0x00];
impl Tag {
/// Translates a tag into its on-the-wire representation