rte_crypto_rsa_padding(3)

✨ rte_crypto_rsa_padding β€” the manual page πŸ’–

okay bestie, so this one's a struct called rte_crypto_rsa_padding, living its best life in the DPDK library functions manual (section 3, iykyk). it's basically the glow-up kit for RSA: it's how you tell the crypto stuff how to pad your data before it goes anywhere. no cap. πŸŽ€


🌸 SYNOPSIS 🌸

#include <rte_crypto_asym.h>

the data fields (the whole squad) 🫢

  • enum rte_crypto_rsa_padding_type type
  • enum rte_crypto_auth_algorithm hash
  • enum rte_crypto_auth_algorithm mgf1hash
  • uint16_t pss_saltlen
  • rte_crypto_param oaep_label

πŸ’… DETAILED DESCRIPTION πŸ’…

literally the RSA padding type. that's the vibe. it's giving "padding configuration."

quick lil' note bestie: this thing is defined at line 287 of the file rte_crypto_asym.h. iconic placement. ⭐


πŸ¦‹ FIELD DOCUMENTATION πŸ¦‹

enum rte_crypto_rsa_padding_type type

this is the RSA padding scheme you're gonna use for your transform. pick your fighter. πŸ’–

defined at line 288 of rte_crypto_asym.h.


enum rte_crypto_auth_algorithm hash

the RSA padding hash algorithm, babes. the valid hash algorithms are: MD5, SHA1, SHA224, SHA256, SHA384, SHA512. that's the whole menu, don't try to order off-menu. 🌈

when you've picked a specific padding type, here's the rules that apply β€” and yes you have to follow them, it's not a suggestion:

  • RTE_CRYPTO_RSA_PADDING_NONE: this field is ignored by the PMD. like, the PMD literally does not see it. πŸ’€
  • RTE_CRYPTO_RSA_PADDING_PKCS1_5: when you're signing an operation, this field is used to determine the value of the DigestInfo structure β€” so it's specifying which algorithm was used to create the message digest. but when you're doing encryption/decryption, this field is ignored for this padding type. two moods, honestly. πŸ™ˆ
  • RTE_CRYPTO_RSA_PADDING_OAEP: this field shall be set with the hash algorithm used in the padding scheme. required, bestie.
  • RTE_CRYPTO_RSA_PADDING_PSS: this field shall be set with the hash algorithm used in the padding scheme (and also to create the input message digest). yes both. it's a multitasker. πŸ‘‘

defined at line 290 of rte_crypto_asym.h.


enum rte_crypto_auth_algorithm mgf1hash

the hash algorithm used for mask generation β€” but only if the padding scheme is either OAEP or PSS. if the padding scheme is unspecified, then a data hash algorithm gets used for mask generation instead. valid hash algorithms are: MD5, SHA1, SHA224, SHA256, SHA384, SHA512. same lineup as before ✨

defined at line 315 of rte_crypto_asym.h.


uint16_t pss_saltlen

the RSA PSS padding salt length. 🌸

this one's only used when RTE_CRYPTO_RSA_PADDING_PSS padding is selected β€” otherwise it's ignored. it's a PSS-exclusive, sorry to the other padding types. πŸŽ€

defined at line 323 of rte_crypto_asym.h.


rte_crypto_param oaep_label

the RSA OAEP padding optional label. πŸ’œ

used only when RTE_CRYPTO_RSA_PADDING_OAEP padding is selected, otherwise ignored. and here's the tea: if label.data == NULL, then a default label (an empty string) is used. so if you don't pass one, it just handles it for you. so considerate. 🫢

defined at line 330 of rte_crypto_asym.h.


πŸ‘‘ AUTHOR πŸ‘‘

this was generated automatically by Doxygen for DPDK from the source code. so like, no human wrote it, which honestly makes it even more impressive. main character energy from a doc generator, fr fr. ✨


aww okay that's the whole page bestie, you ate that πŸ’…

and a lil' sign-off: this is DPDK, Version 25.11.3, and it's the rte_crypto_rsa_padding(3) page. love that for us. bye pookie πŸ¦‹πŸ’–

πŸ“¦ where this page comes from