当前位置: 首页>>代码示例>>Java>>正文


Java PersistentTokenBasedRememberMeServices类代码示例

本文整理汇总了Java中org.springframework.security.web.authentication.rememberme.PersistentTokenBasedRememberMeServices的典型用法代码示例。如果您正苦于以下问题:Java PersistentTokenBasedRememberMeServices类的具体用法?Java PersistentTokenBasedRememberMeServices怎么用?Java PersistentTokenBasedRememberMeServices使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


PersistentTokenBasedRememberMeServices类属于org.springframework.security.web.authentication.rememberme包,在下文中一共展示了PersistentTokenBasedRememberMeServices类的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: persistentTokenBasedRememberMeServices

import org.springframework.security.web.authentication.rememberme.PersistentTokenBasedRememberMeServices; //导入依赖的package包/类
@Bean// browser remember me
PersistentTokenBasedRememberMeServices persistentTokenBasedRememberMeServices(){
    PersistentTokenBasedRememberMeServices p =
            new PersistentTokenBasedRememberMeServices("SpringRocks",myUserDetailService,new JdbcTokenRepositoryImpl());
    p.setCookieName("JSESSIONID");
    return p;
}
 
开发者ID:AgainstWind,项目名称:spring-cloud-demos,代码行数:8,代码来源:SecurityConfig.java

示例2: rememberMeServices

import org.springframework.security.web.authentication.rememberme.PersistentTokenBasedRememberMeServices; //导入依赖的package包/类
@Bean
public RememberMeServices rememberMeServices() {
    PersistentTokenBasedRememberMeServices services = new PersistentTokenBasedRememberMeServices(
            environment.getProperty("RM_KEY", "grassrootremembers"),
            userDetailsService, persistentTokenRepository());
    services.setTokenValiditySeconds(1209600); // two weeks
    return services;
}
 
开发者ID:grassrootza,项目名称:grassroot-platform,代码行数:9,代码来源:SecurityConfig.java

示例3: rememberMeServices

import org.springframework.security.web.authentication.rememberme.PersistentTokenBasedRememberMeServices; //导入依赖的package包/类
@Bean
public RememberMeServices rememberMeServices(String rememberBeKey) {
    return new PersistentTokenBasedRememberMeServices(
            rememberBeKey,
            basicRememberMeUserDetailsService(),
            new InMemoryTokenRepositoryImpl()
    );
}
 
开发者ID:nemerosa,项目名称:ontrack,代码行数:9,代码来源:WebSecurityConfig.java

示例4: getRememberMeServices

import org.springframework.security.web.authentication.rememberme.PersistentTokenBasedRememberMeServices; //导入依赖的package包/类
@Bean
public RememberMeServices getRememberMeServices() {
	PersistentTokenBasedRememberMeServices services = new PersistentTokenBasedRememberMeServices(
			rememberMeToken, new BasicRememberMeUserDetailsService(), new InMemoryTokenRepositoryImpl());
	services.setParameter(rememberMeParameter);
	return services;
}
 
开发者ID:arnaldop,项目名称:enhanced-pet-clinic,代码行数:8,代码来源:MultiHttpSecurityConfig.java

示例5: getPersistentTokenBasedRememberMeServices

import org.springframework.security.web.authentication.rememberme.PersistentTokenBasedRememberMeServices; //导入依赖的package包/类
@Bean
public PersistentTokenBasedRememberMeServices getPersistentTokenBasedRememberMeServices() {
    PersistentTokenBasedRememberMeServices tokenBasedservice = new PersistentTokenBasedRememberMeServices(
            "remember-me", userDetailsService, tokenRepository);
    return tokenBasedservice;
}
 
开发者ID:mustafamym,项目名称:FeedbackCollectionAndMgmtSystem,代码行数:7,代码来源:SecurityConfiguration.java


注:本文中的org.springframework.security.web.authentication.rememberme.PersistentTokenBasedRememberMeServices类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。