Proof-of-concept implementation of ASN.1 mapping #62
Open
uwiger
wants to merge 12 commits from
uw-asn1 into master
pull from: uw-asn1
merge into: :master
:master
:uw-aci
:uw-account-mint
:uw-receive-tx
:uw-asn1
:uw-new-acs
:uw-auth-groups
:uw-ext-account-types
:uw-zomp-vsn-0.2.0
:uw-ac-side-tx-types
:uw-account_seckey
:uw-hash-api-type
:uw-gmser_dyn-rewrite
:uw-save-options
:uw-dyn-options
:uw-anyint
:uw-dynamic-encoding2
:uw-dynamic-encoding
:eureka
:runner
:uw-ac-proposals
:add_token_swap
:add_ga_meta_tx_auth_data_type
:use-latest-enacl-api
:factories
:add-subname-id
Labels
Clear labels
bug
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
bug
duplicate
enhancement
help wanted
invalid
pig lipstick
question
wontfix
Something is not working
This issue or pull request already exists
New feature
Need some help
Something is wrong
Muggle-facing enhancements
More information is needed
This won't be fixed
No labels
Milestone
No items
No Milestone
Projects
Clear projects
No projects
No Assignees
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: QPQ-AG/gmserialization#62
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
This branch contains a proof-of-concept exploration of representing
the RLP (gmser_rlp) and gmserialization layers using ASN.1 with
DER encoding.
Goals of the experiment:
(first byte >= 0xC0 for RLP lists vs. 0x30 for DER SEQUENCE).
to the extremely compact RLP prefix encoding.
for hashing (idempotent serialization).
Key files:
Findings (high level):
TLV tags/lengths and field names in the generic path.
generic templateFields representation.
This is NOT production code. It was created to answer feasibility
questions around ASN.1 modeling, format detection, determinism,
and size characteristics.
Branch created from uw-new-acs for isolated experimentation.
Extended-auth account ids use an {account, Subtype} tag. These helpers let callers test account membership and extract the 32-byte pubkey without pattern-matching on specialize/1 results.ac793dcaf6This branch contains a proof-of-concept exploration of representing the RLP (gmser_rlp) and gmserialization layers using ASN.1 with DER encoding. Goals of the experiment: - Model the static serialization templates and dynamic types in ASN.1. - Demonstrate reliable detection of legacy RLP data vs. new DER data (first byte >= 0xC0 for RLP lists vs. 0x30 for DER SEQUENCE). - Evaluate wire-size overhead of standard DER TLV encoding compared to the extremely compact RLP prefix encoding. - Verify that the DER path produces deterministic output suitable for hashing (idempotent serialization). Key files: - GajumaruSerialization.asn -- the ASN.1 schema - GajumaruSerialization.{erl,hrl} -- generated encoder/decoder - detect_demo.erl, size_comparison.erl -- supporting test code Findings (high level): - Detection via first byte works cleanly. - DER is fully deterministic for hashing when the same value is given. - Small objects pay a significant size overhead (often 3-6x) due to TLV tags/lengths and field names in the generic path. - Concrete SEQUENCE definitions are much more compact than the generic templateFields representation. - Large payloads have acceptable relative overhead. This is NOT production code. It was created to answer feasibility questions around ASN.1 modeling, format detection, determinism, and size characteristics. Branch created from uw-new-acs for isolated experimentation.View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.