Securing Shell using Annotations
@Secured
@ShellMethod(key = "logout", value = "Logout from GitHub. Usage: logout")
public void logout() {
sessionHolder.removeCurrentSession();
}group 'shell'
version '0.0.1'
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'org.springframework.boot:spring-boot-gradle-plugin:1.5.9.RELEASE'
}
}
apply plugin: 'java'
apply plugin: 'groovy'
apply plugin: 'org.springframework.boot'
sourceCompatibility = 1.8
repositories {
mavenCentral()
maven {
url 'https://repo.spring.io/libs-milestone'
}
}
dependencies {
compile 'org.springframework.shell:spring-shell-starter:2.0.0.M2'
compile "org.springframework:spring-aop:4.3.13.RELEASE"
compile "org.springframework:spring-web:4.3.13.RELEASE"
compile "org.aspectj:aspectjrt:1.8.13"
compile "org.aspectj:aspectjweaver:1.8.13"
}Last updated