-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge in RIHA/riha-browser from release to master * commit 'c7093e1918c35b1e8fd3479a3bb9d33129a3cb06': (65 commits) version up version up Fixing sonarqube errors Fixing sonarqube errors Fixing sonarqube errors Fixing sonarqube errors Check for Null Statement Check for Null Statement Check for Null Statement Tests Test auditlog Test auditlog Test remove fix Test remove Test fix Test Fixing sonarqube errors Fixing sonarqube errors Selenium test fix Pull request #201: RIHAKB-1095 ...
- Loading branch information
Showing
76 changed files
with
4,453 additions
and
5,719 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
`Run test` | ||
mvn test -DskipTests=false -Dbrowser=chrome -Durl=https://www.riha.ee |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
34 changes: 34 additions & 0 deletions
34
backend/src/main/java/ee/ria/riha/conf/OAuthConfiguration.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
package ee.ria.riha.conf; | ||
|
||
import org.springframework.context.annotation.Bean; | ||
import org.springframework.context.annotation.Configuration; | ||
import org.springframework.context.annotation.Profile; | ||
import org.springframework.security.oauth2.client.registration.ClientRegistration; | ||
import org.springframework.security.oauth2.client.registration.ClientRegistrationRepository; | ||
import org.springframework.security.oauth2.client.registration.InMemoryClientRegistrationRepository; | ||
import org.springframework.security.oauth2.core.AuthorizationGrantType; | ||
|
||
@Configuration | ||
public class OAuthConfiguration { | ||
|
||
@Bean | ||
@Profile("!dev") | ||
public ClientRegistrationRepository clientRegistrationRepository(ApplicationProperties applicationProperties) { | ||
ApplicationProperties.TaraProperties taraConfig = applicationProperties.getTara(); | ||
return new InMemoryClientRegistrationRepository( | ||
ClientRegistration | ||
.withRegistrationId(taraConfig.getRegistrationId()) | ||
.authorizationUri(taraConfig.getUserAuthorizationUri()) | ||
.clientId(taraConfig.getClientId()) | ||
.clientName(taraConfig.getClientId()) | ||
.clientSecret(taraConfig.getClientSecret()) | ||
.authorizationGrantType(AuthorizationGrantType.AUTHORIZATION_CODE) | ||
.redirectUri(taraConfig.getRegisteredRedirectUri()) | ||
.tokenUri(taraConfig.getAccessTokenUri()) | ||
.jwkSetUri(taraConfig.getJwkKeySetUri()) | ||
.scope(taraConfig.getScope()) | ||
.build() | ||
); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.