Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
STS
Manage
Activity
Members
Labels
Plan
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Coscine
backend
apis
STS
Merge requests
!126
Release: Sprint/2022 11
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Release: Sprint/2022 11
dev
into
master
Overview
0
Commits
2
Pipelines
1
Changes
1
Merged
Petar Hristov
requested to merge
dev
into
master
2 years ago
Overview
0
Commits
2
Pipelines
1
Changes
1
Expand
This Merge Request is automatically created
0
0
Merge request reports
Compare
master
master (base)
and
latest version
latest version
67f1d9d3
2 commits,
2 years ago
1 file
+
15
−
5
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
src/STS/Controllers/ShibbolethController.cs
+
15
−
5
Options
@@ -48,12 +48,22 @@ namespace Coscine.Api.STS.Controllers
entity
=
info
.
Principal
.
FindFirstValue
(
ShibbolethAttributeMapping
.
PairwiseID
);
}
var
identifier
=
entity
[(
entity
.
IndexOf
(
">"
)
+
1
)..];
identifier
=
identifier
.
Substring
(
0
,
identifier
.
IndexOf
(
"<"
));
var
entityId
=
entity
[(
entity
.
IndexOf
(
"NameQualifier=\""
)
+
"NameQualifier=\""
.
Length
)..];
entityId
=
entityId
.
Substring
(
0
,
entityId
.
IndexOf
(
"\""
));
var
identifier
=
""
;
var
entityId
=
""
;
if
(
entity
.
IndexOf
(
">"
)
>
-
1
)
{
identifier
=
entity
[(
entity
.
IndexOf
(
">"
)
+
1
)..];
identifier
=
identifier
.
Substring
(
0
,
identifier
.
IndexOf
(
"<"
));
entityId
=
entity
[(
entity
.
IndexOf
(
"NameQualifier=\""
)
+
"NameQualifier=\""
.
Length
)..];
entityId
=
entityId
.
Substring
(
0
,
entityId
.
IndexOf
(
"\""
));
}
else
{
identifier
=
entity
;
entityId
=
info
.
AuthenticationProperties
.
Items
[
"idp"
];
}
var
mapping
=
externalIdModel
.
GetAllWhere
((
map
)
=>
map
.
ExternalId1
==
identifier
&&
map
.
ExternalAuthenticatorId
==
shibbolethAuthItem
.
Id
Loading