Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add AWS remote auth login #7578

Merged
merged 38 commits into from
Apr 10, 2024
Merged
Show file tree
Hide file tree
Changes from 34 commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
ca02c1c
Add AWS remote auth login
idanovo Mar 19, 2024
ce5b5e0
Add a test
idanovo Mar 19, 2024
692916a
Fix
idanovo Mar 19, 2024
31f7761
Fix logic
idanovo Mar 20, 2024
60389b0
Add relevant tags
idanovo Mar 20, 2024
47ddb2b
Fix
idanovo Mar 20, 2024
b09b303
Fix
idanovo Mar 20, 2024
ed4042f
Fix
idanovo Mar 20, 2024
bde0214
Fix
idanovo Mar 20, 2024
5920fcc
Fix
idanovo Mar 20, 2024
134ba63
Fix PR comments
idanovo Mar 20, 2024
5cb4a8d
Fix
idanovo Mar 20, 2024
e91fe5d
Fix external login API call
idanovo Mar 21, 2024
cab7bdd
merged from master
idanovo Mar 25, 2024
462bee5
Revert
idanovo Mar 25, 2024
0247f49
Fix test
idanovo Mar 25, 2024
fb95a20
Return principal ID instead of user ID for ExternalPrincipalLogin
idanovo Mar 25, 2024
74cbb53
Changed request param
idanovo Mar 27, 2024
d2e77e2
Fix review
idanovo Mar 27, 2024
11bee35
Fix PR comments
idanovo Mar 27, 2024
fec0a34
Fix PR review
idanovo Mar 27, 2024
4628cd0
Merge branch 'master' of https://github.com/treeverse/lakeFS into 757…
idanovo Mar 31, 2024
2e4d425
Add potential status codes
idanovo Apr 2, 2024
714aba7
Fix
idanovo Apr 2, 2024
8fe9e61
Fix PR comments
idanovo Apr 2, 2024
bbbe23e
Fix test
idanovo Apr 2, 2024
9fbc1b0
Lint
idanovo Apr 2, 2024
7d1d27e
Pull from master
idanovo Apr 3, 2024
68422ae
Fix
idanovo Apr 3, 2024
e8a2349
Update docs
idanovo Apr 7, 2024
bf86e73
Merge branch 'master' of https://github.com/treeverse/lakeFS into 757…
idanovo Apr 9, 2024
77f7bb3
PR review
idanovo Apr 9, 2024
77b65c1
Return external login status code
idanovo Apr 10, 2024
6bdbe62
Error handling
idanovo Apr 10, 2024
92f99af
Merge branch 'master' of https://github.com/treeverse/lakeFS into 757…
idanovo Apr 10, 2024
05a794a
PR review
idanovo Apr 10, 2024
1a2755f
Docs update
idanovo Apr 10, 2024
1e5fa4c
Fix docs
idanovo Apr 10, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
58 changes: 58 additions & 0 deletions api/authentication.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,12 +72,24 @@ components:
type: string

responses:
BadRequest:
description: Bad Request
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
Unauthorized:
description: Unauthorized
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
Forbidden:
description: Forbidden
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
ServerError:
description: Internal Server Error
content:
Expand Down Expand Up @@ -280,6 +292,9 @@ components:
external_user_identifier:
type: string
description: external_user_identifier is the user DN in LDAP set if user exists with that username and has this password.
IdentityRequest:
type: object

StsAuthRequest:
type: object
required:
Expand All @@ -303,6 +318,15 @@ components:
additionalProperties:
type: string
description: the claims of the token returned from the provider

ExternalPrincipal:
type: object
required:
- id
properties:
id:
type: string

paths:
/ldap/login:
post:
Expand All @@ -328,6 +352,40 @@ paths:
$ref: "#/components/responses/Unauthorized"
default:
$ref: "#/components/responses/ServerError"

/auth/external/principal/login:
post:
tags:
- auth
- external
operationId: externalPrincipalLogin
summary: perform a login using an external authenticator
security: [ ]
requestBody:
content:
application/json:
schema:
$ref: "#/components/schemas/IdentityRequest"
responses:
200:
description: successful external login
content:
application/json:
schema:
$ref: "#/components/schemas/ExternalPrincipal"
400:
$ref: "#/components/responses/BadRequest"
401:
$ref: "#/components/responses/Unauthorized"
403:
$ref: "#/components/responses/Forbidden"
404:
$ref: "#/components/responses/NotFound"
420:
description: too many requests
default:
$ref: "#/components/responses/ServerError"

/sts/login:
post:
tags:
Expand Down
53 changes: 50 additions & 3 deletions api/swagger.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ components:
type: apiKey
in: cookie
name: saml_auth_session

parameters:
PaginationPrefix:
in: query
Expand Down Expand Up @@ -1049,6 +1050,17 @@ components:
type: string
secret_access_key:
type: string

ExternalLoginInformation:
type: object
Isan-Rivkin marked this conversation as resolved.
Show resolved Hide resolved
required:
- identityRequest
properties:
token_expiration_duration:
type: integer
identityRequest:
type: object

StsAuthRequest:
type: object
required:
Expand All @@ -1066,8 +1078,8 @@ components:
type: integer
format: int64
description: |
The time-to-live for the generated token in seconds. The maximum
value is 3600 seconds (1 hour) max is 12 hours.
The time-to-live for the generated token in seconds. The default
value is 3600 seconds (1 hour) maximum time allowed is 12 hours.
AuthenticationToken:
type: object
required:
Expand Down Expand Up @@ -1820,6 +1832,40 @@ paths:
description: too many requests
default:
$ref: "#/components/responses/ServerError"

/auth/external/principal/login:
post:
tags:
- external
- experimental
Isan-Rivkin marked this conversation as resolved.
Show resolved Hide resolved
operationId: externalPrincipalLogin
summary: perform a login using an external authenticator
security: []
requestBody:
content:
application/json:
schema:
$ref: "#/components/schemas/ExternalLoginInformation"
responses:
200:
description: successful external login
content:
application/json:
schema:
$ref: "#/components/schemas/AuthenticationToken"
400:
$ref: "#/components/responses/BadRequest"
401:
$ref: "#/components/responses/Unauthorized"
403:
$ref: "#/components/responses/Forbidden"
404:
$ref: "#/components/responses/NotFound"
420:
description: too many requests
default:
$ref: "#/components/responses/ServerError"

/sts/login:
post:
tags:
Expand All @@ -1842,10 +1888,11 @@ paths:
$ref: "#/components/schemas/AuthenticationToken"
401:
$ref: "#/components/responses/Unauthorized"
420:
description: too many requests
default:
$ref: "#/components/responses/ServerError"


/auth/capabilities:
get:
tags:
Expand Down
3 changes: 3 additions & 0 deletions clients/java-legacy/.openapi-generator/FILES

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions clients/java-legacy/README.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

72 changes: 70 additions & 2 deletions clients/java-legacy/api/openapi.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading