diff --git a/pkg/auth/manager/publicshares/publicshares.go b/pkg/auth/manager/publicshares/publicshares.go index 3739999d98..05eabc47f1 100644 --- a/pkg/auth/manager/publicshares/publicshares.go +++ b/pkg/auth/manager/publicshares/publicshares.go @@ -128,6 +128,9 @@ func (m *manager) Authenticate(ctx context.Context, token, secret string) (*user if err != nil { return nil, nil, err } + if getUserResponse.Status.Code != rpcv1beta1.Code_CODE_OK { + return nil, nil, errtypes.NotFound(getUserResponse.Status.Message) + } share := publicShareResponse.GetShare() role := authpb.Role_ROLE_VIEWER