From b454f4697f9df5400386256fbaafc578e50210d3 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Zden=C4=9Bk=20Salvet?= Date: Tue, 28 Aug 2007 09:46:36 +0000 Subject: [PATCH] Don't allow registering job over unauthenticated direct connection. --- org.glite.lb.server/src/store.c.T | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/org.glite.lb.server/src/store.c.T b/org.glite.lb.server/src/store.c.T index 4a2fa1d..6c99416 100644 --- a/org.glite.lb.server/src/store.c.T +++ b/org.glite.lb.server/src/store.c.T @@ -535,7 +535,8 @@ static int check_auth(edg_wll_Context ctx,edg_wll_Event *e) edg_wll_ResetError(ctx); if (e->type == EDG_WLL_EVENT_REGJOB) - return strcmp(e->any.user,EDG_WLL_LOG_USER_DEFAULT) ? + return ((ctx->isProxy || ctx->peerName) && + strcmp(e->any.user,EDG_WLL_LOG_USER_DEFAULT)) ? 0 : edg_wll_SetError(ctx,EPERM,"can't register jobs anonymously"); trio_asprintf(&q,"select userid from jobs where jobid='%|Ss'",jobid); -- 1.8.2.3