View gist:e9517ca80c927c421d5ca43bc019325a
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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Google OAuth2</title> | |
<link rel="stylesheet" href="./css/bootstrap.min.css"> | |
<link rel="stylesheet" href="./css/app.css"> | |
</head> | |
<body> |
View gist:7955e3b86c781a218eea6eaf53ad0c51
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
<plugin> | |
<groupId>com.spotify</groupId> | |
<artifactId>docker-maven-plugin</artifactId> | |
<executions> | |
<execution> | |
<phase>install</phase> | |
<goals> | |
<goal>build</goal> | |
</goals> | |
</execution> |
View OAuthSecurityConfig.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
import org.springframework.beans.factory.annotation.Autowired; | |
import org.springframework.beans.factory.annotation.Configurable; | |
import org.springframework.boot.autoconfigure.security.oauth2.resource.ResourceServerProperties; | |
import org.springframework.boot.autoconfigure.security.oauth2.resource.UserInfoTokenServices; | |
import org.springframework.security.config.annotation.authentication.builders.AuthenticationManagerBuilder; | |
import org.springframework.security.config.annotation.web.builders.HttpSecurity; | |
import org.springframework.security.config.annotation.web.builders.WebSecurity; | |
import org.springframework.security.config.annotation.web.configuration.EnableWebSecurity; | |
import org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter; | |
import org.springframework.security.oauth2.client.OAuth2ClientContext; |
View UserRestController.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
import org.springframework.web.bind.annotation.RequestMapping; | |
import org.springframework.web.bind.annotation.RequestMethod; | |
import org.springframework.web.bind.annotation.RestController; | |
import java.security.Principal; | |
@RestController | |
@RequestMapping("/") | |
public class UserRestController { |
View index.html
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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Google OAuth2</title> | |
<link rel="stylesheet" href="./css/bootstrap.min.css"> | |
<link rel="stylesheet" href="./css/app.css"> | |
</head> | |
<body> |
View pom.xml
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
<dependency> | |
<groupId>com.bea.core</groupId> | |
<artifactId>commons.security.api</artifactId> | |
<version>1.0</version> | |
<scope>system</scope> | |
<systemPath> | |
${oracle.home}/12.1.3.0/wlserver/modules/com.oracle.css.common.security.api_7.1.0.0.jar | |
</systemPath> | |
</dependency> |
View pom.xml
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
<properties> | |
<oracle.home>/app/wls</oracle.home> | |
<weblogic.version>12.1.1.0</weblogic.version> | |
<domain.dir>/app/wls/12.1.3.0/wlserver/server/</domain.dir> | |
<maven.compiler.source>1.6</maven.compiler.source> | |
<maven.compiler.target>1.6</maven.compiler.target> | |
<jar.file> | |
${project.build.directory}/${project.build.finalName}.jar | |
</jar.file> | |
<package.dir>com/weblogic/security</package.dir> |
View pom.xml
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
<properties> | |
<oracle.home>/app/wls</oracle.home> | |
<weblogic.version>12.1.1.0</weblogic.version> | |
<domain.dir>/app/wls/12.1.3.0/wlserver/server/</domain.dir> | |
<maven.compiler.source>1.6</maven.compiler.source> | |
<maven.compiler.target>1.6</maven.compiler.target> | |
<jar.file> | |
${project.build.directory}/${project.build.finalName}.jar | |
</jar.file> | |
<package.dir>com/weblogic/security</package.dir> |
View pom.xml
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
<build> | |
<resources> | |
<resource> | |
<filtering>true</filtering> | |
<directory>src/main/resources</directory> | |
</resource> | |
</resources> | |
<plugins> | |
<plugin> | |
<groupId>org.zeroturnaround</groupId> |
View pom.xml
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
<profiles> | |
<profile> | |
<id>tools-jar-in-plugin</id> | |
<activation> | |
<os> | |
<family>linux</family> | |
</os> | |
</activation> | |
<build> | |
<plugins> |
OlderNewer