From e682fda3c386d7cd87714d076e344b309c54e751 Mon Sep 17 00:00:00 2001 From: guoxiuyan Date: Tue, 3 Feb 2015 09:56:37 +0800 Subject: [PATCH] Fix DISABLE_TOKEN_AUTH flag check in docker_registry/toolkit.py When we set DISABLE_TOKEN_AUTH to true, there are two functions that should check the flag, but only one function does. Signed-off-by: Guo Xiuyan --- docker_registry/toolkit.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker_registry/toolkit.py b/docker_registry/toolkit.py index 5a35c88a7..3fcea22b6 100644 --- a/docker_registry/toolkit.py +++ b/docker_registry/toolkit.py @@ -119,7 +119,7 @@ def response(data=None, code=200, headers=None, raw=False): def validate_parent_access(parent_id): - if cfg.standalone: + if cfg.disable_token_auth is True or cfg.standalone is True: return True auth = _parse_auth_header() if not auth: