fix
authorSchanzenbach, Martin <mschanzenbach@posteo.de>
Fri, 28 Sep 2018 06:33:58 +0000 (08:33 +0200)
committerSchanzenbach, Martin <mschanzenbach@posteo.de>
Fri, 28 Sep 2018 06:33:58 +0000 (08:33 +0200)
src/rest-plugins/plugin_rest_openid_connect.c
src/rest-plugins/plugin_rest_reclaim.c

index 6456458a6875f955b1386a6d96d6c4de7462f61d..2bb60efce63ff1bf91d84be7ef31564f50b68508 100644 (file)
@@ -1381,7 +1381,6 @@ check_authorization (struct RequestHandle *handle,
   if (0 != strcmp ("Basic", credentials))
   {
     handle->emsg=GNUNET_strdup("invalid_client");
-    handle->edesc = GNUNET_strdup ("1");
     handle->response_code = MHD_HTTP_UNAUTHORIZED;
     return GNUNET_SYSERR;
   }
@@ -1389,7 +1388,6 @@ check_authorization (struct RequestHandle *handle,
   if (NULL == credentials)
   {
     handle->emsg=GNUNET_strdup("invalid_client");
-    handle->edesc = GNUNET_strdup ("2");
     handle->response_code = MHD_HTTP_UNAUTHORIZED;
     return GNUNET_SYSERR;
   }
@@ -1408,7 +1406,6 @@ check_authorization (struct RequestHandle *handle,
   {
     GNUNET_free_non_null(basic_authorization);
     handle->emsg=GNUNET_strdup("invalid_client");
-    handle->edesc = GNUNET_strdup ("Wrong username");
     handle->response_code = MHD_HTTP_UNAUTHORIZED;
     return GNUNET_SYSERR;
   }
@@ -1417,7 +1414,6 @@ check_authorization (struct RequestHandle *handle,
   {
     GNUNET_free_non_null(basic_authorization);
     handle->emsg=GNUNET_strdup("invalid_client");
-    handle->edesc = GNUNET_strdup (client_id);
     handle->response_code = MHD_HTTP_UNAUTHORIZED;
     return GNUNET_SYSERR;
   }
@@ -1431,7 +1427,6 @@ check_authorization (struct RequestHandle *handle,
     {
       GNUNET_free_non_null(basic_authorization);
       GNUNET_free(expected_pass);
-      handle->edesc = GNUNET_strdup (pass);
       handle->emsg=GNUNET_strdup("invalid_client");
       handle->response_code = MHD_HTTP_UNAUTHORIZED;
       return GNUNET_SYSERR;
index 208c7470e4ac73dfaf170ea81704f73e56f15bac..ccc2d894b30c43d09a0943b751719050b9af7103 100644 (file)
@@ -587,6 +587,7 @@ add_attribute_cont (struct GNUNET_REST_RequestHandle *con_handle,
     return;
   }
   handle->idp = GNUNET_RECLAIM_connect (cfg);
+  exp = GNUNET_TIME_UNIT_HOURS;
   handle->idp_op = GNUNET_RECLAIM_attribute_store (handle->idp,
                                                    identity_priv,
                                                    attribute,