[PATCH 6.1 286/291] sign-file,extract-cert: move common SSL helper functions to a header