Contents · Forum Home · StreamSec Tools 4.1.5.363 documentation

DkimRecordName

function DkimRecordName(const aSelector, aDomain: string): string;
Vectors: RFC 6376 Appendix A and RFC 8463 Appendix A - signatures produced by someone else - plus the canonicalization edge cases and the policy refusals. True = all pass; aFailedStep names the first that did not. Needs the DSI provider units linked (see the unit header). PUBLISHING THE PUBLIC HALF. Signing is useless until a verifier can fetch the key, and the two ends have to agree exactly, so these build the record rather than leaving an operator to assemble one from a hex dump.

DkimRecordName is the owner name a verifier queries - '<selector>._domainkey.<domain>', record type TXT.

DkimPublicKeyRecord is the record VALUE, ready to paste into a zone: 'v=DKIM1; k=rsa; p=<base64 SubjectPublicKeyInfo>' for rsa-sha256, or 'v=DKIM1; k=ed25519; p=<base64 of the bare 32 octets>' for ed25519-sha256. The difference between those two encodings is the thing most easily got wrong by hand: RFC 8463 sec.3 makes the Ed25519 form the RAW key, not an SPKI, and a verifier handed the wrong one sees a key it cannot parse.

aKey is whatever the signer signs with - a key COMPONENT (TstRSAKey, TstEdDSAKey; it is asked for an interface, so the component answers) or a bare key interface. Only the PUBLIC half is read.