extract RSA key utility functions

Functions to constract crypto-pubkey private key and public key data
will be needed for RSASSA-PSS signing as well as PKCS1-V1_5, so
extract that code to non-exported functions 'rsaPrivateKey' and
'rsaPublicKey'.