Loading app/ADL/api/auth.py +1 −1 Original line number Diff line number Diff line Loading @@ -25,7 +25,7 @@ class JWTBearer(HTTPBearer): raise HTTPException(status_code=status.HTTP_403_FORBIDDEN, detail="Invalid authentication scheme.") try: openid_config = requests.get(f'{str(config.oidc_url)}/.well-known/openid-configuration').json() openid_config = requests.get(f'{str(config.oidc_url)}.well-known/openid-configuration').json() jwks_client = PyJWKClient(openid_config['jwks_uri']) signing_key = jwks_client.get_signing_key_from_jwt(credentials.credentials) auth_data = jwt.decode( Loading app/ADL/api/models.py +1 −1 Original line number Diff line number Diff line Loading @@ -78,4 +78,4 @@ class ARMFiles(Model): @property_field def url(self) -> AnyHttpUrl: return f'{config.host_url}/fs/stream/{self.name}' return f'{config.host_url}/v1_0/fs/stream/{self.name}' app/ADL/client/__init__.py +2 −2 Original line number Diff line number Diff line Loading @@ -53,7 +53,7 @@ class Archive(object): env_token = os.environ.get('ADL_TOKEN') if username and password: self.auth_data = requests.post( f'{str(config.endpoint)}get_token/', f'{str(config.endpoint)}/get_token', auth=(username, password) ).json() elif env_token: Loading Loading @@ -97,7 +97,7 @@ class Archive(object): 'start_time': self.start_time, 'end_time': self.end_time } return requests.get(f'{str(config.endpoint)}/file_list/', params=payload).json() return requests.get(f'{str(config.endpoint)}/fs/file_list/', params=payload).json() def download(self, destination): with ThreadPoolExecutor(config.download_threads) as pool: Loading app/ADL/client/config.py +1 −1 Original line number Diff line number Diff line Loading @@ -5,7 +5,7 @@ from pydantic import AnyHttpUrl, BaseSettings class Settings(BaseSettings): debug: bool = True endpoint: AnyHttpUrl = 'http://localhost:8000/v1_0/fs' endpoint: AnyHttpUrl = 'http://localhost:8000/v1_0' download_chunk_size: int = 8192 download_threads: int = None Loading Loading
app/ADL/api/auth.py +1 −1 Original line number Diff line number Diff line Loading @@ -25,7 +25,7 @@ class JWTBearer(HTTPBearer): raise HTTPException(status_code=status.HTTP_403_FORBIDDEN, detail="Invalid authentication scheme.") try: openid_config = requests.get(f'{str(config.oidc_url)}/.well-known/openid-configuration').json() openid_config = requests.get(f'{str(config.oidc_url)}.well-known/openid-configuration').json() jwks_client = PyJWKClient(openid_config['jwks_uri']) signing_key = jwks_client.get_signing_key_from_jwt(credentials.credentials) auth_data = jwt.decode( Loading
app/ADL/api/models.py +1 −1 Original line number Diff line number Diff line Loading @@ -78,4 +78,4 @@ class ARMFiles(Model): @property_field def url(self) -> AnyHttpUrl: return f'{config.host_url}/fs/stream/{self.name}' return f'{config.host_url}/v1_0/fs/stream/{self.name}'
app/ADL/client/__init__.py +2 −2 Original line number Diff line number Diff line Loading @@ -53,7 +53,7 @@ class Archive(object): env_token = os.environ.get('ADL_TOKEN') if username and password: self.auth_data = requests.post( f'{str(config.endpoint)}get_token/', f'{str(config.endpoint)}/get_token', auth=(username, password) ).json() elif env_token: Loading Loading @@ -97,7 +97,7 @@ class Archive(object): 'start_time': self.start_time, 'end_time': self.end_time } return requests.get(f'{str(config.endpoint)}/file_list/', params=payload).json() return requests.get(f'{str(config.endpoint)}/fs/file_list/', params=payload).json() def download(self, destination): with ThreadPoolExecutor(config.download_threads) as pool: Loading
app/ADL/client/config.py +1 −1 Original line number Diff line number Diff line Loading @@ -5,7 +5,7 @@ from pydantic import AnyHttpUrl, BaseSettings class Settings(BaseSettings): debug: bool = True endpoint: AnyHttpUrl = 'http://localhost:8000/v1_0/fs' endpoint: AnyHttpUrl = 'http://localhost:8000/v1_0' download_chunk_size: int = 8192 download_threads: int = None Loading