> On 28 Oct 2024, at 08:06, Viktor Dukhovni via mailop <mailop@mailop.org> > wrote: > > On Mon, Oct 28, 2024 at 07:48:42AM +0000, Pete Long wrote: > >>> On 28 Oct 2024, at 05:32, Viktor Dukhovni via mailop <mailop@mailop.org> >>> wrote: >>> >>> Mind you, why is there a trailing "#" at the end of the "p=" value, >>> that's not a valid Base64 character, and is not expected here. The >>> correct encoding is without the trailing "#": >>> >>> "v=DKIM1; k=rsa; >>> p=MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAtWeIDz1pdmR1f4ZIs2SOOoXkMaYu0iOnHzPoJpZ2xwvT8uFLauG6IfkIEtZwFJ/t9R2qq6fdrn9YT3GhkEgWOM6o6dFpfxqqtQXtwaExHGIIf7EPG2m2WM+LZpkBRjl60FpE4BKwrGbaxdBJ3i1XYiGaNElFcRkvdj+pWxPd6/AL9O3a5IxdXuoQ7qaC0St20" >>> >>> "TYXjTdQx0dlAp3HU4MLletOBei6YzlfDYwvKtDbiavP6i3MwVI3qfxOs1UqvVXiKcrrdGzM44YqGnpGkstAhkDO/5XRUVES/anCqyjCyfhfoHjfVeo35ThxP99D2aZ+vVVoRtqR8D2xWIGA1PpcAQIDAQAB" >> >> Thanks Viktor. I ran these commands I found in search result to generate a >> new DKIM key pair yesterday and the public key does end up with a hash >> symbol: >> >> >> # openssl genrsa -out valar_dkim_private.pem 2048 >> >> # openssl ec -in valar_dkim_private.pem -pubout -outform der | openssl >> base64 -A > > 1. The key is an RSA key, the fact that "openssl ec" can also read it, > is a happy coincidence, you should use "openssl pkey" instead. > > 2. That "#" was not part of the output, it was rather your "root" shell > *prompt*, because "openssl base64 -A" output is not newline terminated. >
Nice one, thank you. I have saved your post in case I need those commands again. Pete. _______________________________________________ mailop mailing list mailop@mailop.org https://list.mailop.org/listinfo/mailop