Why remove trailing padding from base64 encoded fingerprint?

Mark Leonard mark at bernoullinetworks.com
Thu Sep 12 00:07:29 AEST 2019


>From sshkey.c (line 925):

        /* Trim padding characters from end */
        ret[strcspn(ret, "=")] = '\0';
        return ret;

Why remove the trailing padding from the Base64 encoded key fingerprint?  I
recognize that it's easy enough to re-pad the string, but I'm just curious
why it's being removed in the first place.

Thanks,
Mark


More information about the openssh-unix-dev mailing list