Skip to content

Add per-user browser session duration controls - #203

Merged
bifrost0x merged 2 commits into
mainfrom
dev/user-session-duration
Sep 6, 2026
Merged

Add per-user browser session duration controls#203
bifrost0x merged 2 commits into
mainfrom
dev/user-session-duration

Conversation

@bifrost0x

@bifrost0x bifrost0x commented Sep 6, 2026

Copy link
Copy Markdown
Owner

Summary

  • add a bounded per-user duration for normal browser sign-ins under Settings → Preferences
  • retain the current 30-minute default and offer explicit 1, 2, 4, and 8-hour choices
  • explain that browser authentication expiry is independent of SSH idle timeout and applies from the next sign-in
  • keep the separate seven-day "Remember me" behavior unchanged

Background

Discussion #201 exposed a deterministic disconnect after roughly 30 minutes. The authentication hardening introduced an absolute server-side browser-session expiry, and subsequent Socket.IO enforcement correctly rejected even the keep-alive event once that authentication record expired. The fail-closed behavior was intentional, but the fixed default and its relationship to an active SSH session were not visible to users.

Security properties

  • 30 minutes remains the default
  • the server accepts only an exact allowlist of durations, with an 8-hour maximum
  • there is no unlimited or sliding-expiration option
  • authentication-session records, account-generation checks, ownership enforcement, and revocation on logout, account lock, or deletion remain intact
  • Flask's signed cookie window is only an outer 8-hour ceiling; the per-user server-side authentication record remains authoritative
  • invalid or corrupt preference data falls back to the secure 30-minute default

Validation

  • pytest -q: 2,387 passed and 29 skipped
  • focused authentication, preferences, UI, shell, i18n, static-delivery, and documentation tests passed
  • JavaScript tests: 39 passed
  • Playwright settings and management regression tests: 8 passed
  • ESLint and git diff --check passed

Related: #201

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 6, 2026

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-09-06T13:04:08.241771Z 1b7e196 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 72a996cd60

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread app/auth_assurance.py
@bifrost0x bifrost0x self-assigned this Sep 6, 2026
@bifrost0x

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. You're on a roll.

Reviewed commit: 1b7e19606a

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@bifrost0x
bifrost0x merged commit 7e6cc81 into main Sep 6, 2026
20 of 21 checks passed
@bifrost0x
bifrost0x deleted the dev/user-session-duration branch September 6, 2026 13:06
@github-project-automation github-project-automation Bot moved this from Backlog to Done in WebSSH Roadmap Sep 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant