Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
Démonstration auth VR
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ViaRézo
Formations
Démonstration auth VR
Commits
f9dc7a35
Verified
Commit
f9dc7a35
authored
4 months ago
by
Arthur Conrozier
Browse files
Options
Downloads
Patches
Plain Diff
comment and .env
parent
d436e603
Branches
Branches containing commit
No related tags found
1 merge request
!1
Updating main
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
.env.template
+2
-1
2 additions, 1 deletion
.env.template
main.py
+1
-1
1 addition, 1 deletion
main.py
with
3 additions
and
2 deletions
.env.template
+
2
−
1
View file @
f9dc7a35
...
@@ -4,3 +4,4 @@ AUTHORIZATION_URL="https://auth.viarezo.fr/oauth/authorize"
...
@@ -4,3 +4,4 @@ AUTHORIZATION_URL="https://auth.viarezo.fr/oauth/authorize"
TOKEN_URL="https://auth.viarezo.fr/oauth/token"
TOKEN_URL="https://auth.viarezo.fr/oauth/token"
USERINFO_URL="https://auth.viarezo.fr/oidc/userinfo"
USERINFO_URL="https://auth.viarezo.fr/oidc/userinfo"
LOGOUT_URL="https://auth.viarezo.fr/logout"
LOGOUT_URL="https://auth.viarezo.fr/logout"
SESSION_SECRET="my-super-secret"
\ No newline at end of file
This diff is collapsed.
Click to expand it.
main.py
+
1
−
1
View file @
f9dc7a35
...
@@ -20,7 +20,7 @@ app.secret_key = SESSION_SECRET
...
@@ -20,7 +20,7 @@ app.secret_key = SESSION_SECRET
app
.
config
[
'
SESSION_COOKIE_HTTPONLY
'
]
=
True
# Prevents JavaScript access to the cookie
app
.
config
[
'
SESSION_COOKIE_HTTPONLY
'
]
=
True
# Prevents JavaScript access to the cookie
app
.
config
[
'
SESSION_COOKIE_SECURE
'
]
=
True
# Ensures the cookie is only sent over HTTPS
app
.
config
[
'
SESSION_COOKIE_SECURE
'
]
=
True
# Ensures the cookie is only sent over HTTPS
app
.
config
[
'
SESSION_COOKIE_SAMESITE
'
]
=
'
Lax
'
# Mitigates CSRF attacks
app
.
config
[
'
SESSION_COOKIE_SAMESITE
'
]
=
'
Lax
'
# Mitigates CSRF attacks
app
.
config
[
'
SESSION_TYPE
'
]
=
'
redis
'
# Use Redis to store sessions
app
.
config
[
'
SESSION_TYPE
'
]
=
'
redis
'
# Use Redis to store sessions
(server-side)
app
.
config
[
'
SESSION_PERMANENT
'
]
=
False
# Session is deleted when the browser is closed
app
.
config
[
'
SESSION_PERMANENT
'
]
=
False
# Session is deleted when the browser is closed
app
.
config
[
'
SESSION_USE_SIGNER
'
]
=
True
# Sign the session cookie
app
.
config
[
'
SESSION_USE_SIGNER
'
]
=
True
# Sign the session cookie
app
.
config
[
'
SESSION_KEY_PREFIX
'
]
=
'
oauth_
'
# Prefix for session keys
app
.
config
[
'
SESSION_KEY_PREFIX
'
]
=
'
oauth_
'
# Prefix for session keys
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment