SELinux SET @pub = create_asymmetric_pub_key(’DSA’, @priv); SET @dhp = create_dh_parameters(1024); 6.7 SELinux 1601 Security-Enhanced Linux (SELinux) is a mandatory access control (MAC) system that implements access rights by applying a security label referred to as an  SELinux context  to each system object. SELinux policy The resulting digest string is suitable for use with  asymmetric_sign()  and  asymmetric_verify() SET @dig = create_digest(’SHA512’, The quick brown fox’); Supported  digest_type  values:  ’SHA224’ ,  ’SHA256’ ,  ’SHA384’ ,  ’SHA512’ Creates a digest from the given string using the given digest type, and returns the digest as a binary string. If digest generation fails, the result is  NULL . • create_digest( digest_type ,  str ) For an example showing how to use the return value for generating symmetric keys, see the description of  asymmetric_derive() . Supported  key_len  values: The minimum and maximum key lengths in bits are 1,024 and 10,000. These key-length limits are constraints imposed by OpenSSL. Server administrators can impose additional limits on maximum key length by setting environment variables. See Section 6.6.2, “MySQL Enterprise Encryption Usage and Examples” . Creates a shared secret for generating a DH private/public key pair and returns a binary string that can be passed to  create_asymmetric_priv_key() . If secret generation fails, the result is null. • create_asymmetric_pub_key( algorithm ,  priv_key_str ) •Generation of DH keys takes much longer than RSA or RSA keys. •Asymmetric encryption functions are slower than symmetric functions. If performance is an important factor and the functions are to be used very frequently, you are better off using symmetric encryption. For example, consider using  AES_ENCRYPT()  and  AES_DECRYPT() . • create_dh_parameters( key_len ) •The strength of encryption for private and public keys increases with the key size, but the time for key generation increases as well. For an example showing DH key generation, see the description of  asymmetric_derive() . Some general considerations in choosing key lengths and encryption algorithms: Derives a public key from the given private key using the given algorithm, and returns the key as a binary string in PEM format. If key derivation fails, the result is  NULL . priv_key_str  must be a valid key string in PEM format.  algorithm  indicates the encryption algorithm used to create the key. Supported  algorithm  values:  ’RSA’ ,  ’DSA’ ,  ’DH’ For a usage example, see the description of  create_asymmetric_priv_key() .