zoukankan      html  css  js  c++  java
  • shiro标签说明

    • guest标签

      <shiro:guest>

      </shiro:guest>

      用户没有身份验证时显示相应信息,即游客访问信息。

    • user标签

      <shiro:user>  

      </shiro:user>

      用户已经身份验证/记住我登录后显示相应的信息。

    • authenticated标签

      <shiro:authenticated>  

      </shiro:authenticated>

      用户已经身份验证通过,即Subject.login登录成功,不是记住我登录的。

    • notAuthenticated标签

      <shiro:notAuthenticated>

      </shiro:notAuthenticated>

      用户已经身份验证通过,即没有调用Subject.login进行登录,包括记住我自动登录的也属于未进行身份验证。

    • principal标签

      <shiro: principal/>

      <shiro:principal property="username"/>

      相当于((User)Subject.getPrincipals()).getUsername()。

    • lacksPermission标签

      <shiro:lacksPermission name="org:create">

      </shiro:lacksPermission>

      如果当前Subject没有权限将显示body体内容。

    • hasRole标签

      <shiro:hasRole name="admin">  

      </shiro:hasRole>

      如果当前Subject有角色将显示body体内容。

    • hasAnyRoles标签

      <shiro:hasAnyRoles name="admin,user">

      </shiro:hasAnyRoles>

      如果当前Subject有任意一个角色(或的关系)将显示body体内容。

    • lacksRole标签

      <shiro:lacksRole name="abc">  

      </shiro:lacksRole>

      如果当前Subject没有角色将显示body体内容。

    • hasPermission标签

      <shiro:hasPermission name="user:create">  

      </shiro:hasPermission>

      如果当前Subject有权限将显示body体内容

  • 相关阅读:
    解决WampServer窗口界面乱码问题
    PHP 中空字符串介绍0、null、empty和false之间的关系
    位(bit)、字节(byte)、字
    SQL GROUP BY 和 ORDER BY 区别
    爬虫安装相关软件
    nginx自动切割日志脚本
    tengine日志切割-配置分钟级别日志自动切割
    flutter进行自动编译操作步骤
    03-字符编码-读写模式-课堂笔记
    04-函数-课堂笔记
  • 原文地址:https://www.cnblogs.com/mafy/p/11887364.html
Copyright © 2011-2022 走看看