Rename psa_generate_random_key back to psa_generate_key
generate_key is a more classical name. The longer name was only
introduced to avoid confusion with getting a key from a generator,
which is key derivation, but we no longer use the generator
terminology so this reason no longer applies.
perl -i -pe 's/psa_generate_random_key/psa_generate_key/g' $(git ls-files)
diff --git a/docs/getting_started.md b/docs/getting_started.md
index ac1bc31..9ab4f8f 100644
--- a/docs/getting_started.md
+++ b/docs/getting_started.md
@@ -494,7 +494,7 @@
Generate a piece of random 128-bit AES data:
1. Set the key policy for key generation by calling `psa_key_policy_set_usage()` with the `PSA_KEY_USAGE_EXPORT` parameter and the algorithm `PSA_ALG_GCM`.
-1. Generate a random AES key by calling `psa_generate_random_key()`.
+1. Generate a random AES key by calling `psa_generate_key()`.
1. Export the generated key by calling `psa_export_key()`:
```C
int slot = 1;
@@ -510,7 +510,7 @@
psa_set_key_policy(slot, &policy);
/* Generate a key */
- psa_generate_random_key(slot, PSA_KEY_TYPE_AES, bits);
+ psa_generate_key(slot, PSA_KEY_TYPE_AES, bits);
psa_export_key(slot, exported, exported_size, &exported_length)