Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
auth
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
id
auth
Commits
848aebc7
Commit
848aebc7
authored
2 years ago
by
ale
Browse files
Options
Downloads
Patches
Plain Diff
Minor clarifications in the docs
parent
0c11710e
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
README.md
+10
-5
10 additions, 5 deletions
README.md
with
10 additions
and
5 deletions
README.md
+
10
−
5
View file @
848aebc7
...
...
@@ -293,8 +293,10 @@ configured with the following attributes:
The known queries are identified by name. It does not matter what
operations you do as long as the queries take the expected input
substitution parameters, and return rows with the expected number of
fields (column names do not matter). You should use the parameter
substitution symbol `?` as placeholder for query parameters.
fields (column names do not matter). Note that the order of returned
columns is critical, and it should match what is documented here. You
should use the parameter substitution symbol `?` as placeholder for
query parameters.
* `get_user` takes a single parameter (the user name) and must return
a single row with *email*, *password*, *TOTP secret* and *shard*
...
...
@@ -334,12 +336,12 @@ CREATE TABLE group_memberships (
group_name text NOT NULL
);
CREATE INDEX group_memberships_idx ON group_memberships(email);
CREATE TABLE
u2f
_registrations (
CREATE TABLE
webauthn
_registrations (
email text NOT NULL,
key_handle blob NOT NULL,
public_key blob NOT NULL
);
CREATE INDEX
u2f
_registrations_idx ON
u2f
_registrations(email);
CREATE INDEX
webauthn
_registrations_idx ON
webauthn
_registrations(email);
CREATE TABLE service_passwords (
email text NOT NULL,
service text NOT NULL,
...
...
@@ -348,6 +350,9 @@ CREATE TABLE service_passwords (
CREATE INDEX service_passwords_idx ON service_passwords(email);
```
(Note: this isn't a great schema example due to the lack of
referential integrity, it's just useful as an example)
With this schema, one could use the following configuration for a
service:
...
...
@@ -361,7 +366,7 @@ services:
queries:
get_user: "SELECT email, password, totp_secret, shard FROM users WHERE email = ?"
get_user_groups: "SELECT group_name FROM group_memberships WHERE email = ?"
get_user_u2f: "SELECT public_key, key_handle FROM
u2f
_registrations WHERE email = ?"
get_user_u2f: "SELECT public_key, key_handle FROM
webauthn
_registrations WHERE email = ?"
get_user_asp: "SELECT service, password FROM service_passwords WHERE email = ?"
```
...
...
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