# Selection of cryptographic functions for OAEP

I can't understand how the "cryptographic functions" are to be selected RSA + OAEP which are used in OAEP. How to choose these "cryptographic functions"(G and H)?

-

Since this picture is taken from wikipedia, I suggest reading the text beside that picture:

• G and H are typically some cryptographic hash functions fixed by the protocol.

I think you're asking how OAEP and RSA actually are combined, and it goes like this:

• Use OAEP (choose $r$, follow the instructions and you get $X$ and $Y$)
• Concatenate $X$ and $Y$, interpret it as an integer (length has to be lower than the RSA keylength)
• Use this number in RSA.

For decryption, reverse the process.

-
Wikipaedia says "G and H are typically some cryptographic hash functions fixed by the protocol.". I don't understand it. –  Sahil Sareen Mar 14 at 12:36
I assume you know what cryptographic hash functions are (wikipedia), but there are quite a lot of them. And which one is chosen is up to the protocol designer. For example, RFC 3447 describes RSA-OAEP, but they didn't fix a hash function either but leave it as an optional parameter. That means in practice, you use e.g. RSA-OAEP with SHA-256. –  tylo Mar 14 at 13:24