67,512
社区成员
发帖
与我相关
我的任务
分享
<bean id="securityManager" class="org.apache.shiro.web.mgt.DefaultWebSecurityManager">
<property name="realm" ref="shiroDbRealm" />
<property name="cacheManager" ref="shiroEhcacheManager" />
</bean>
<!-- 項目自定义的Realm, 所有accountService依赖的dao都需要用depends-on声明 -->
<bean id="shiroDbRealm" class="com.dnake.cloudparking.auth.AuthRealm" depends-on="userDao,userWechatDao,parkingTicketDao,userParkingTicketDao,jdbcQueryDao">
<property name="userService" ref="userService" />
</bean>
<!--
<bean id="sessionFilter"
class="com.dnake.cloudparking.auth.SessionFilter"> </bean>
-->
<bean id="shiroFilter" class="org.apache.shiro.spring.web.ShiroFilterFactoryBean">
<property name="securityManager" ref="securityManager" />
<property name="loginUrl" value="/login" />
<property name="successUrl" value="/index" />
<!--
<property name="filters"> <map> <entry key="sessionFilter"
value-ref="sessionFilter"/> </map> </property>
-->
<property name="filterChainDefinitions">
<value>
/ = anon
/login.jsp= anon
/index.jsp = anon
/login = anon
/syslogin = anon
/loginval = anon
/syslogout = anon
/servlet/AuthImageServlet = anon
/getBackPwdStep* = anon
/backuncheck/** = anon
/weixin/** = anon
/alipay/** = anon
/static/**= anon
/res/** = anon
/api/** = anon
/createScanQrCodeOrder = anon
/weixin/payNotify = anon
/alipay/payNotify = anon
/wxpay_refund_notify = anon
/register/** = anon
/app/* = anon
/parking.jsp = anon
/video.html = anon
/saveParking = anon
/admin/** =roles[admin]
/** = user
</value>
</property>