-
Notifications
You must be signed in to change notification settings - Fork 545
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Introduce JDBC based persistence for SAML #6287
base: master
Are you sure you want to change the base?
Conversation
93f9d76
to
f25b8dc
Compare
"An error occurred while retrieving the " + "the service provider with the issuer '%s'", issuer), | ||
e); | ||
} | ||
if (serviceProviderDO == null) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lets convert this to,
if (serviceProviderDO != null) {
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #6287 +/- ##
============================================
+ Coverage 45.89% 46.03% +0.13%
- Complexity 14420 14492 +72
============================================
Files 1654 1657 +3
Lines 103215 103587 +372
Branches 18203 18251 +48
============================================
+ Hits 47375 47688 +313
- Misses 49062 49085 +23
- Partials 6778 6814 +36
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
try { | ||
String tenantDomain = IdentityTenantUtil.getTenantDomain(tenantId); | ||
// Load the certificate stored in the database, if signature validation is enabled. | ||
if (serviceProviderDO.isDoValidateSignatureInRequests() || | ||
serviceProviderDO.isDoValidateSignatureInArtifactResolve() || | ||
serviceProviderDO.isDoEnableEncryptedAssertion()) { | ||
|
||
Tenant tenant = IdentityTenantUtil.getTenant(tenantId); | ||
serviceProviderDO.setX509Certificate(getApplicationCertificate(serviceProviderDO, tenant)); | ||
} | ||
serviceProviderDO.setTenantDomain(tenantDomain); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can't we move this logic to the manager?
public boolean isServiceProviderExists(String issuer, int tenantId) throws IdentityException { | ||
|
||
try { | ||
return processIsServiceProviderExists(issuer, tenantId); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lets move processIsServiceProviderExists
impl to here.
|
||
List<SAMLSSOServiceProviderDO> serviceProvidersList; | ||
try { | ||
serviceProvidersList = processGetServiceProviders(tenantId); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lets move processGetServiceProviders
impl to here.
public boolean removeServiceProvider(String issuer, int tenantId) throws IdentityException { | ||
|
||
try { | ||
processDeleteServiceProvider(issuer, tenantId); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lets move processDeleteServiceProvider
impl here
SAMLSSOServiceProviderDO serviceProviderDO = null; | ||
|
||
try { | ||
serviceProviderDO = processGetServiceProvider(issuer, tenantId); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lets move processGetServiceProvider
impl here.
f25b8dc
to
480caf6
Compare
Quality Gate failedFailed conditions |
Introduce JDBC based persistence for SAML. Related to,