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 Session tracker to DB, App, and Windows Desktop Sessions #12304

Merged
merged 44 commits into from
May 12, 2022

Conversation

Joerger
Copy link
Contributor

@Joerger Joerger commented Apr 28, 2022

This PR generalizes session tracker logic and extends it to DB, App, and Windows Desktop sessions.

Issue background: #12131 (comment)

TODO:

  • Add session tracker to...
    • DB
    • App
    • Windows Desktop
  • Manually test that sessions upload as expected:
    • DB
    • App
    • Windows Desktop

Fixes #12131, #12232

@Joerger Joerger force-pushed the joerger/track-all-sessions branch from cfb1e18 to b731877 Compare April 28, 2022 19:25
Copy link
Collaborator

@r0mant r0mant left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know it's a draft, just took a quick look.

api/client/proto/authservice.proto Outdated Show resolved Hide resolved
api/types/types.proto Outdated Show resolved Hide resolved
lib/srv/db/mongodb/engine.go Outdated Show resolved Hide resolved
Joerger added 5 commits April 29, 2022 17:20
Deprectate CreateSessionTracker in backwards compatible way.

Add Session tracker helper functions.

Update kube session tracker expiry logic.

Add session tracker to db sessions.
@Joerger Joerger force-pushed the joerger/track-all-sessions branch from 48443c0 to d01ad4a Compare April 30, 2022 00:24
@Joerger Joerger force-pushed the joerger/track-all-sessions branch from 38ebdb7 to 4020281 Compare May 2, 2022 20:28
@Joerger Joerger marked this pull request as ready for review May 2, 2022 20:35
@github-actions github-actions bot requested review from codingllama and hatched May 2, 2022 20:35
@github-actions github-actions bot added application-access audit-log Issues related to Teleports Audit Log database-access Database access related issues and PRs desktop-access kubernetes labels May 2, 2022
Copy link
Contributor

@codingllama codingllama left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Partial review, will wrap-up tomorrow.

api/client/proto/authservice.proto Outdated Show resolved Hide resolved
api/client/proto/authservice.proto Outdated Show resolved Hide resolved
api/client/client.go Show resolved Hide resolved
lib/auth/auth_with_roles.go Outdated Show resolved Hide resolved
lib/auth/auth_with_roles.go Outdated Show resolved Hide resolved
lib/auth/auth_with_roles.go Outdated Show resolved Hide resolved
lib/auth/grpcserver.go Outdated Show resolved Hide resolved
lib/srv/db/common/auth.go Outdated Show resolved Hide resolved
lib/kube/proxy/sess.go Outdated Show resolved Hide resolved
@Joerger Joerger requested a review from r0mant May 2, 2022 22:26
@Joerger Joerger force-pushed the joerger/track-all-sessions branch from ac19479 to 4d0de2e Compare May 2, 2022 22:28
@Joerger Joerger force-pushed the joerger/track-all-sessions branch from 4d0de2e to c3a826f Compare May 2, 2022 22:53
Copy link
Collaborator

@r0mant r0mant left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@xacrimon Can you take a look as well?

lib/srv/app/session.go Outdated Show resolved Hide resolved
lib/srv/sessiontracker.go Outdated Show resolved Hide resolved
lib/srv/sessiontracker.go Outdated Show resolved Hide resolved
@r0mant r0mant requested review from xacrimon and removed request for hatched May 10, 2022 00:20
Copy link
Contributor

@xacrimon xacrimon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nothing other what @r0mant found

@Joerger Joerger force-pushed the joerger/track-all-sessions branch from 96fc4c1 to d865ed6 Compare May 10, 2022 23:53
@Joerger Joerger requested a review from r0mant May 10, 2022 23:53
lib/srv/app/session.go Outdated Show resolved Hide resolved
lib/srv/app/session.go Outdated Show resolved Hide resolved
@Joerger Joerger merged commit b4eec0d into master May 12, 2022
@Joerger Joerger deleted the joerger/track-all-sessions branch May 12, 2022 18:15
Joerger added a commit that referenced this pull request Oct 6, 2022
* Complete deprecation for OIDC RedirectURL - #12054.

* Complete deprecation for CreateSessionTracker - #12304.

* Complete deprecation for SSO Auth Request http endpoints - #13073.

* Complete deprecation for #12795.

* Complete deprecation for http GenerateToken - #9024.
Joerger added a commit that referenced this pull request Oct 6, 2022
* Complete deprecation for OIDC RedirectURL - #12054.

* Complete deprecation for CreateSessionTracker - #12304.

* Complete deprecation for SSO Auth Request http endpoints - #13073.

* Complete deprecation for #12795.

* Complete deprecation for http GenerateToken - #9024.
Joerger added a commit that referenced this pull request Oct 6, 2022
* Complete deprecation for OIDC RedirectURL - #12054.

* Complete deprecation for CreateSessionTracker - #12304.

* Complete deprecation for SSO Auth Request http endpoints - #13073.

* Complete deprecation for #12795.

* Complete deprecation for http GenerateToken - #9024.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
application-access audit-log Issues related to Teleports Audit Log backport-required database-access Database access related issues and PRs desktop-access kubernetes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Failed to upload DB session
5 participants