Separate OpenPGP model API from struct storage
Bug #1153659 reported by
Casey Marshall
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
hockeypuck |
Fix Committed
|
Medium
|
Casey Marshall |
Bug Description
The structures in pgp_types.go should be abstracted into interfaces. Basically, replace the names PubKey, UserId, UserAttribute, Signature, etc with interfaces and getter methods.
Underlying struct implementations can then adapt more closely with the backend model representation -- Mongo backend model can differ from PostgreSQL, go.crypto/openpgp structures can be used directly as a backend store instead of duplicating the data.
To post a comment you must log in.
This went down a little differently than I'd planned, but the OpenPGP models have definitely been refactored, and there's now a clear distinction and relationship between RFC4880 and the database representation.