diff options
author | Schanzenbach, Martin <mschanzenbach@posteo.de> | 2018-09-28 00:17:58 +0200 |
---|---|---|
committer | Schanzenbach, Martin <mschanzenbach@posteo.de> | 2018-09-28 00:17:58 +0200 |
commit | ec50a665dc884f7997419d0351ae8ade9c1aeabe (patch) | |
tree | 1ee4bb59fbd313b7e6e9a8a3ea0c69a29ec75c88 /src | |
parent | 7a5a724a6f96baf80d2226326124aa01c58ad3fe (diff) | |
download | gnunet-ec50a665dc884f7997419d0351ae8ade9c1aeabe.tar.gz gnunet-ec50a665dc884f7997419d0351ae8ade9c1aeabe.zip |
revert
Diffstat (limited to 'src')
-rw-r--r-- | src/rest-plugins/plugin_rest_openid_connect.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/rest-plugins/plugin_rest_openid_connect.c b/src/rest-plugins/plugin_rest_openid_connect.c index 500ecec11..6456458a6 100644 --- a/src/rest-plugins/plugin_rest_openid_connect.c +++ b/src/rest-plugins/plugin_rest_openid_connect.c | |||
@@ -128,7 +128,7 @@ | |||
128 | /** | 128 | /** |
129 | * OIDC cookie header information key | 129 | * OIDC cookie header information key |
130 | */ | 130 | */ |
131 | #define OIDC_AUTHORIZATION_HEADER_KEY "Authorization" | 131 | #define OIDC_AUTHORIZATION_HEADER_KEY "authorization" |
132 | 132 | ||
133 | /** | 133 | /** |
134 | * OIDC cookie header information key | 134 | * OIDC cookie header information key |
@@ -1381,6 +1381,7 @@ check_authorization (struct RequestHandle *handle, | |||
1381 | if (0 != strcmp ("Basic", credentials)) | 1381 | if (0 != strcmp ("Basic", credentials)) |
1382 | { | 1382 | { |
1383 | handle->emsg=GNUNET_strdup("invalid_client"); | 1383 | handle->emsg=GNUNET_strdup("invalid_client"); |
1384 | handle->edesc = GNUNET_strdup ("1"); | ||
1384 | handle->response_code = MHD_HTTP_UNAUTHORIZED; | 1385 | handle->response_code = MHD_HTTP_UNAUTHORIZED; |
1385 | return GNUNET_SYSERR; | 1386 | return GNUNET_SYSERR; |
1386 | } | 1387 | } |
@@ -1388,6 +1389,7 @@ check_authorization (struct RequestHandle *handle, | |||
1388 | if (NULL == credentials) | 1389 | if (NULL == credentials) |
1389 | { | 1390 | { |
1390 | handle->emsg=GNUNET_strdup("invalid_client"); | 1391 | handle->emsg=GNUNET_strdup("invalid_client"); |
1392 | handle->edesc = GNUNET_strdup ("2"); | ||
1391 | handle->response_code = MHD_HTTP_UNAUTHORIZED; | 1393 | handle->response_code = MHD_HTTP_UNAUTHORIZED; |
1392 | return GNUNET_SYSERR; | 1394 | return GNUNET_SYSERR; |
1393 | } | 1395 | } |
@@ -1406,6 +1408,7 @@ check_authorization (struct RequestHandle *handle, | |||
1406 | { | 1408 | { |
1407 | GNUNET_free_non_null(basic_authorization); | 1409 | GNUNET_free_non_null(basic_authorization); |
1408 | handle->emsg=GNUNET_strdup("invalid_client"); | 1410 | handle->emsg=GNUNET_strdup("invalid_client"); |
1411 | handle->edesc = GNUNET_strdup ("Wrong username"); | ||
1409 | handle->response_code = MHD_HTTP_UNAUTHORIZED; | 1412 | handle->response_code = MHD_HTTP_UNAUTHORIZED; |
1410 | return GNUNET_SYSERR; | 1413 | return GNUNET_SYSERR; |
1411 | } | 1414 | } |
@@ -1414,6 +1417,7 @@ check_authorization (struct RequestHandle *handle, | |||
1414 | { | 1417 | { |
1415 | GNUNET_free_non_null(basic_authorization); | 1418 | GNUNET_free_non_null(basic_authorization); |
1416 | handle->emsg=GNUNET_strdup("invalid_client"); | 1419 | handle->emsg=GNUNET_strdup("invalid_client"); |
1420 | handle->edesc = GNUNET_strdup (client_id); | ||
1417 | handle->response_code = MHD_HTTP_UNAUTHORIZED; | 1421 | handle->response_code = MHD_HTTP_UNAUTHORIZED; |
1418 | return GNUNET_SYSERR; | 1422 | return GNUNET_SYSERR; |
1419 | } | 1423 | } |
@@ -1427,6 +1431,7 @@ check_authorization (struct RequestHandle *handle, | |||
1427 | { | 1431 | { |
1428 | GNUNET_free_non_null(basic_authorization); | 1432 | GNUNET_free_non_null(basic_authorization); |
1429 | GNUNET_free(expected_pass); | 1433 | GNUNET_free(expected_pass); |
1434 | handle->edesc = GNUNET_strdup (pass); | ||
1430 | handle->emsg=GNUNET_strdup("invalid_client"); | 1435 | handle->emsg=GNUNET_strdup("invalid_client"); |
1431 | handle->response_code = MHD_HTTP_UNAUTHORIZED; | 1436 | handle->response_code = MHD_HTTP_UNAUTHORIZED; |
1432 | return GNUNET_SYSERR; | 1437 | return GNUNET_SYSERR; |