import { TagListRecord } from "./TagListRecord.js"; import { ConstantTag } from "../tags/ConstantTag.js"; import { EnumTag } from "../tags/EnumTag.js"; import { TextTag } from "../tags/TextTag.js"; import { FlagsTag } from "../tags/FlagsTag.js"; export class DkimRecord extends TagListRecord { static fields = [ new ConstantTag("v", "DKIM1") .required() .hidden() .pos(0), new TextTag("p") .label("Public key") .desc("Base64-encoded public key data") .required() .pos(1), new EnumTag("k", ["rsa", "ed25519"]) .label("Key type") .desc("") .options(["RSA", "Ed25519"]) .default("rsa") .pos(1), new FlagsTag("t", ["y", "s"]) .label("Flags") .options(["Test mode", "Strict mode (Recommended)"]) .optionDesc([ "Indicates the server is currently testing DKIM support", "Require identical domain in i= and d= tags of DKIM signature (Recommended unless using subdomains)", ]) .default("") .pos(1), new EnumTag("h", ["sha1", "sha256"]) .label("Hash algorithms") .desc("Which hash algorithms are allowed to be used. If not set, all are allowed") .options(["SHA-1", "SHA-256"]) .category("advanced") .pos(1), new TextTag("n") .label("Note") .desc("Any extra comments for humans. Not parsed by machines") .category("advanced") .default("") .pos(1), new EnumTag("s", ["*", "email"]) .disabled() .default("*") .pos(1), ]; static categories = { "advanced": "Advanced", }; }