yxh
2026-09-15 a87c0376bd72a04bb4def026b03b82dd01b7e169
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
package cn.lihu.jh.framework.security.core.annotations;
 
import java.lang.annotation.*;
 
/**
 * 声明用户需要登录
 *
 * 为什么不使用 {@link org.springframework.security.access.prepost.PreAuthorize} 注解,原因是不通过时,抛出的是认证不通过,而不是未登录
 *
 * @author 芋道源码
 */
@Target({ElementType.METHOD})
@Retention(RetentionPolicy.RUNTIME)
@Inherited
@Documented
public @interface PreAuthenticated {
}