commit 45c851d9e84ae27ca51905a66c1b0191867a7c99
parent e719693588c989691e2c24b44e821eea5c6fcdcd
Author: Martin Schanzenbach <schanzen@gnunet.org>
Date: Mon, 23 Jun 2025 18:11:08 +0200
scope s/admin/all
Diffstat:
2 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/src/backend/taler-merchant-httpd.c b/src/backend/taler-merchant-httpd.c
@@ -245,14 +245,14 @@ struct ScopePermissionMap
struct ScopePermissionMap scope_permissions[] = {
/* Deprecated since v19 */
{
- .as = TMH_AS_ADMIN,
+ .as = TMH_AS_ALL,
.name = "write",
.permissions = "*"
},
/* Full access */
{
- .as = TMH_AS_ADMIN,
- .name = "admin",
+ .as = TMH_AS_ALL,
+ .name = "all",
.permissions = "*"
},
/* Read-only access */
@@ -2214,7 +2214,7 @@ url_handler (void *cls,
control), as we then also have no data to protect. */
if (0 == GNUNET_CONTAINER_multihashmap_size (TMH_by_id_map))
{
- hc->auth_scope = TMH_AS_ADMIN;
+ hc->auth_scope = TMH_AS_ALL;
}
else if (is_basic_auth)
{
@@ -2242,7 +2242,7 @@ url_handler (void *cls,
if (GNUNET_OK ==
check_auth_instance (auth,
hc->instance))
- hc->auth_scope = TMH_AS_ADMIN;
+ hc->auth_scope = TMH_AS_ALL;
else
hc->auth_scope = TMH_AS_NONE;
}
@@ -2254,7 +2254,7 @@ url_handler (void *cls,
if (GNUNET_is_zero (&hc->instance->auth.auth_hash))
{
/* hash zero means no authentication for instance */
- hc->auth_scope = TMH_AS_ADMIN;
+ hc->auth_scope = TMH_AS_ALL;
}
else
{
@@ -2297,7 +2297,7 @@ url_handler (void *cls,
}
else
{
- hc->auth_scope = TMH_AS_ADMIN;
+ hc->auth_scope = TMH_AS_ALL;
}
GNUNET_free (dec);
}
diff --git a/src/backend/taler-merchant-httpd.h b/src/backend/taler-merchant-httpd.h
@@ -452,7 +452,7 @@ enum TMH_AuthScope
/**
* Full access is granted to everything.
*/
- TMH_AS_ADMIN = 7 | 1 << 30,
+ TMH_AS_ALL = 7 | 1 << 30,
/**
* /login access to renew the token is OK.