Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Jetsam Server
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Package Registry
Operate
Terraform modules
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jetsam
Jetsam Server
Commits
6d9bee80
Verified
Commit
6d9bee80
authored
4 years ago
by
Louis
Browse files
Options
Downloads
Patches
Plain Diff
Add definitions for oauth scopes
parent
6d067dd7
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
src/domain/auth/AuthServer.js
+28
-1
28 additions, 1 deletion
src/domain/auth/AuthServer.js
with
28 additions
and
1 deletion
src/domain/auth/AuthServer.js
+
28
−
1
View file @
6d9bee80
...
...
@@ -194,6 +194,8 @@ class KoaOAuthServer {
const
scopes
=
describeScopeRequest
(
query
.
scope
)
console
.
log
(
scopes
)
return
ctx
.
render
(
'
auth/accept-oauth
'
,
{
user
,
client
,
...
...
@@ -252,7 +254,32 @@ const scopeDescriptionMap = {
icon
:
'
admin
'
,
name
:
'
Full Access
'
,
description
:
'
Full access to your account, including the ability to create, update and delete any user information, metrics and files.
'
}
},
'
metrics:create
'
:
{
name
:
'
Create Metrics
'
,
description
:
'
The ability to add data metrics linked to your account. Remember that connected apps that create metrics will know your location!
'
,
},
'
files:upload
'
:
{
name
:
'
Upload Files
'
,
description
:
'
The ability to upload images linked to your account
'
,
},
'
files:read
'
:
{
name
:
'
Read Files
'
,
description
:
'
The ability to see and download images that you
\'
ve uploaded to your account
'
,
},
'
profile:read
'
:
{
name
:
'
Read Profile
'
,
description
:
'
The ability to see any information associated with your user profile. This includes your name and email address
'
,
},
'
profile:write
'
:
{
name
:
'
Modify Profile
'
,
description
:
'
The ability to edit any information associated with your user profile. This includes your name
'
,
},
'
profile:stats
'
:
{
name
:
'
Profile Stats
'
,
description
:
'
The ability to see information about your account stats, including your points and citizen scientist level
'
,
},
}
function
describeScopeRequest
(
scope
=
'
*
'
)
{
const
scopes
=
scope
.
split
(
'
'
)
...
...
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