Complete the code to define a role with read privileges on the index 'logs'.
{
"role": {
"indices": [
{
"names": ["logs"],
"privileges": ["[1]"]
}
]
}
}The read privilege allows a role to read data from the specified index.
Complete the code to assign the role 'log_reader' to the user 'alice'.
{
"username": "alice",
"roles": ["[1]"]
}The user 'alice' is assigned the role 'log_reader' to grant her specific access rights.
Fix the error in the role definition by completing the missing privilege to allow document deletion.
{
"role": {
"indices": [
{
"names": ["logs"],
"privileges": ["[1]"]
}
]
}
}The delete privilege allows the role to delete documents from the index.
Fill both blanks to create a role that allows reading and writing on the 'metrics' index.
{
"role": {
"indices": [
{
"names": ["metrics"],
"privileges": ["[1]", "[2]"]
}
]
}
}The role needs both read and write privileges to allow reading and writing data.
Fill all three blanks to define a user with username 'bob', password 'secret', and assign the role 'metrics_admin'.
{
"username": "[1]",
"password": "[2]",
"roles": ["[3]"]
}The username is 'bob', the password is 'secret', and the assigned role is 'metrics_admin'.