2017.2.13 开涛shiro教程-第十二章-与Spring集成(一)配置文件详解
原博客地址:http://jinnianshilongnian.iteye.com/blog/2018398
根据下载的pdf学习。
第十二章-与Spring集成(一)配置文件详解
1.pom.xml
1 junit 2 3 common-logging 4 common-collections 5 6 shiro-core 7 shiro-web 8 shiro-ehcache 9 shiro-quartz 10 shiro-spring 11 12 spring-context 13 spring-aop 14 spring-jdbc 15 spring-web 16 spring-webmvc 17 spring-test 18 19 mysql-connector-java 20 druid 21 22 javax.servlet-api 23 javax.servlet-jsp 24 25 aspectjrt 26 aspectjweaver
1 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 2 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> 3 <parent> 4 <artifactId>shiro-example</artifactId> 5 <groupId>com.github.zhangkaitao</groupId> 6 <version>1.0-SNAPSHOT</version> 7 </parent> 8 <modelVersion>4.0.0</modelVersion> 9 <artifactId>shiro-example-chapter12</artifactId> 10 <packaging>war</packaging> 11 <name>shiro-example-chapter12</name> 12 <url>http://maven.apache.org</url> 13 14 <dependencies> 15 <dependency> 16 <groupId>junit</groupId> 17 <artifactId>junit</artifactId> 18 <version>4.9</version> 19 <scope>test</scope> 20 </dependency> 21 <dependency> 22 <groupId>org.springframework</groupId> 23 <artifactId>spring-test</artifactId> 24 <version>4.0.0.RELEASE</version> 25 <scope>test</scope> 26 </dependency> 27 28 <dependency> 29 <groupId>commons-logging</groupId> 30 <artifactId>commons-logging</artifactId> 31 <version>1.1.3</version> 32 </dependency> 33 <dependency> 34 <groupId>commons-collections</groupId> 35 <artifactId>commons-collections</artifactId> 36 <version>3.2.1</version> 37 </dependency> 38 39 <dependency> 40 <groupId>org.apache.shiro</groupId> 41 <artifactId>shiro-core</artifactId> 42 <version>1.2.2</version> 43 </dependency> 44 45 <dependency> 46 <groupId>org.apache.shiro</groupId> 47 <artifactId>shiro-web</artifactId> 48 <version>1.2.2</version> 49 </dependency> 50 51 <dependency> 52 <groupId>org.apache.shiro</groupId> 53 <artifactId>shiro-ehcache</artifactId> 54 <version>1.2.2</version> 55 </dependency> 56 57 <dependency> 58 <groupId>org.apache.shiro</groupId> 59 <artifactId>shiro-quartz</artifactId> 60 <version>1.2.2</version> 61 </dependency> 62 63 <dependency> 64 <groupId>org.apache.shiro</groupId> 65 <artifactId>shiro-spring</artifactId> 66 <version>1.2.2</version> 67 </dependency> 68 69 70 <dependency> 71 <groupId>mysql</groupId> 72 <artifactId>mysql-connector-java</artifactId> 73 <version>5.1.25</version> 74 </dependency> 75 <dependency> 76 <groupId>com.alibaba</groupId> 77 <artifactId>druid</artifactId> 78 <version>0.2.23</version> 79 </dependency> 80 81 <dependency> 82 <groupId>javax.servlet</groupId> 83 <artifactId>javax.servlet-api</artifactId> 84 <version>3.0.1</version> 85 <scope>provided</scope> 86 </dependency> 87 <dependency> 88 <groupId>javax.servlet.jsp</groupId> 89 <artifactId>jsp-api</artifactId> 90 <version>2.2</version> 91 </dependency> 92 <dependency> 93 <groupId>javax.servlet</groupId> 94 <artifactId>jstl</artifactId> 95 <version>1.2</version> 96 </dependency> 97 98 99 <!-- aspectj相关jar包--> 100 <dependency> 101 <groupId>org.aspectj</groupId> 102 <artifactId>aspectjrt</artifactId> 103 <version>1.7.4</version> 104 </dependency> 105 <dependency> 106 <groupId>org.aspectj</groupId> 107 <artifactId>aspectjweaver</artifactId> 108 <version>1.7.4</version> 109 </dependency> 110 111 <dependency> 112 <groupId>org.springframework</groupId> 113 <artifactId>spring-context</artifactId> 114 <version>4.0.0.RELEASE</version> 115 </dependency> 116 117 <dependency> 118 <groupId>org.springframework</groupId> 119 <artifactId>spring-aop</artifactId> 120 <version>4.0.0.RELEASE</version> 121 </dependency> 122 123 124 <dependency> 125 <groupId>org.springframework</groupId> 126 <artifactId>spring-jdbc</artifactId> 127 <version>4.0.0.RELEASE</version> 128 </dependency> 129 130 <dependency> 131 <groupId>org.springframework</groupId> 132 <artifactId>spring-web</artifactId> 133 <version>4.0.0.RELEASE</version> 134 </dependency> 135 136 <dependency> 137 <groupId>org.springframework</groupId> 138 <artifactId>spring-webmvc</artifactId> 139 <version>4.0.0.RELEASE</version> 140 </dependency> 141 142 143 </dependencies> 144 145 <build> 146 <finalName>chapter12</finalName> 147 <plugins> 148 <plugin> 149 <groupId>org.mortbay.jetty</groupId> 150 <artifactId>jetty-maven-plugin</artifactId> 151 <version>8.1.8.v20121106</version> 152 <configuration> 153 <webAppConfig> 154 <contextPath>/${project.build.finalName}</contextPath> 155 </webAppConfig> 156 </configuration> 157 </plugin> 158 159 <plugin> 160 <groupId>org.apache.tomcat.maven</groupId> 161 <artifactId>tomcat7-maven-plugin</artifactId> 162 <version>2.2</version> 163 <configuration> 164 <path>/${project.build.finalName}</path> 165 </configuration> 166 167 </plugin> 168 </plugins> 169 170 171 </build> 172 173 </project>
2.web.xml
1 Spring配置 2 涉及配置文件: classpath:spring-beans.xml,classpath:spring-shiro-web.xml 4 ShiroFilter配置 5 Springmvc 配置 6 涉及配置文件:classpath:spring-mvc.xml
1 <?xml version="1.0" encoding="UTF-8"?> 2 <web-app 3 xmlns="http://java.sun.com/xml/ns/javaee" 4 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 5 xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd" 6 version="3.0" 7 metadata-complete="false"> 8 9 <!-- Spring配置文件开始 --> 10 <context-param> 11 <param-name>contextConfigLocation</param-name> 12 <param-value> 13 classpath:spring-beans.xml, 14 classpath:spring-shiro-web.xml 15 </param-value> 16 </context-param> 17 <listener> 18 <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class> 19 </listener> 20 <!-- Spring配置文件结束 --> 21 22 <!-- shiro 安全过滤器 --> 23 <!-- The filter-name matches name of a 'shiroFilter' bean inside applicationContext.xml --> 24 <filter> 25 <filter-name>shiroFilter</filter-name> 26 <filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class> 27 <async-supported>true</async-supported> 28 <init-param> 29 <param-name>targetFilterLifecycle</param-name> 30 <param-value>true</param-value> 31 </init-param> 32 </filter> 33 34 <filter-mapping> 35 <filter-name>shiroFilter</filter-name> 36 <url-pattern>/*</url-pattern> 37 </filter-mapping> 38 39 <!--spring mvc--> 40 <servlet> 41 <servlet-name>spring</servlet-name> 42 <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class> 43 <init-param> 44 <param-name>contextConfigLocation</param-name> 45 <param-value>classpath:spring-mvc.xml</param-value> 46 </init-param> 47 <load-on-startup>1</load-on-startup> 48 <async-supported>true</async-supported> 49 </servlet> 50 <servlet-mapping> 51 <servlet-name>spring</servlet-name> 52 <url-pattern>/</url-pattern> 53 </servlet-mapping> 54 55 56 </web-app>
3.spring-beans.xml
1 <?xml version="1.0" encoding="UTF-8"?> 2 <beans xmlns="http://www.springframework.org/schema/beans" 3 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 4 xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd"> 5 6 <!-- 数据库连接池 --> 7 <bean id="dataSource" class="com.alibaba.druid.pool.DruidDataSource"> 8 <property name="driverClassName" value="com.mysql.jdbc.Driver"/> 9 <property name="url" value="jdbc:mysql://localhost:3306/shiro"/> 10 <property name="username" value="root"/> 11 <property name="password" value=""/> 12 </bean> 13 14 <!-- Base DAO --> 15 <bean id="baseDao" abstract="true"> 16 <property name="dataSource" ref="dataSource"/> 17 </bean> 18 19 <!-- DAO --> 20 <bean id="permissionDao" class="com.github.zhangkaitao.shiro.chapter12.dao.PermissionDaoImpl" parent="baseDao"/> 21 <bean id="roleDao" class="com.github.zhangkaitao.shiro.chapter12.dao.RoleDaoImpl" parent="baseDao"/> 22 <bean id="userDao" class="com.github.zhangkaitao.shiro.chapter12.dao.UserDaoImpl" parent="baseDao"/> 23 24 <!-- Service --> 25 <bean id="permissionService" class="com.github.zhangkaitao.shiro.chapter12.service.PermissionServiceImpl"> 26 <property name="permissionDao" ref="permissionDao"/> 27 </bean> 28 29 <bean id="roleService" class="com.github.zhangkaitao.shiro.chapter12.service.RoleServiceImpl"> 30 <property name="roleDao" ref="roleDao"/> 31 </bean> 32 33 <bean id="passwordHelper" class="com.github.zhangkaitao.shiro.chapter12.service.PasswordHelper"> 34 <property name="algorithmName" value="md5"/> 35 <property name="hashIterations" value="2"/> 36 </bean> 37 38 <bean id="userService" class="com.github.zhangkaitao.shiro.chapter12.service.UserServiceImpl"> 39 <property name="userDao" ref="userDao"/> 40 <property name="passwordHelper" ref="passwordHelper"/> 41 </bean> 42 43 44 </beans>
4.spring-shiro.xml
提供了普通JavaSE独立应用的spring-shiro配置。即只要把之前的ini参数,翻译为此处的spring xml配置方式即可。
1 <?xml version="1.0" encoding="UTF-8"?> 2 <beans xmlns="http://www.springframework.org/schema/beans" 3 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 4 xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd"> 5 6 <!-- 缓存管理器 使用Ehcache实现 --> 7 <bean id="cacheManager" class="org.apache.shiro.cache.ehcache.EhCacheManager"> 8 <property name="cacheManagerConfigFile" value="classpath:ehcache.xml"/> 9 </bean> 10 11 <!-- 凭证匹配器 --> 12 <bean id="credentialsMatcher" class="com.github.zhangkaitao.shiro.chapter12.credentials.RetryLimitHashedCredentialsMatcher"> 13 <constructor-arg ref="cacheManager"/> 14 <property name="hashAlgorithmName" value="md5"/> 15 <property name="hashIterations" value="2"/> 16 <property name="storedCredentialsHexEncoded" value="true"/> 17 </bean> 18 19 <!-- Realm实现 --> 20 <bean id="userRealm" class="com.github.zhangkaitao.shiro.chapter12.realm.UserRealm"> 21 <property name="userService" ref="userService"/> 22 <property name="credentialsMatcher" ref="credentialsMatcher"/> 23 <property name="cachingEnabled" value="true"/> 24 <property name="authenticationCachingEnabled" value="true"/> 25 <property name="authenticationCacheName" value="authenticationCache"/> 26 <property name="authorizationCachingEnabled" value="true"/> 27 <property name="authorizationCacheName" value="authorizationCache"/> 28 </bean> 29 30 <!-- 会话ID生成器 --> 31 <bean id="sessionIdGenerator" class="org.apache.shiro.session.mgt.eis.JavaUuidSessionIdGenerator"/> 32 <!-- 会话DAO --> 33 <bean id="sessionDAO" class="org.apache.shiro.session.mgt.eis.EnterpriseCacheSessionDAO"> 34 <property name="activeSessionsCacheName" value="shiro-activeSessionCache"/> 35 <property name="sessionIdGenerator" ref="sessionIdGenerator"/> 36 </bean> 37 <!-- 会话验证调度器 --> 38 <bean id="sessionValidationScheduler" class="org.apache.shiro.session.mgt.quartz.QuartzSessionValidationScheduler"> 39 <property name="sessionValidationInterval" value="1800000"/> 40 <property name="sessionManager" ref="sessionManager"/> 41 </bean> 42 <!-- 会话管理器 --> 43 <bean id="sessionManager" class="org.apache.shiro.session.mgt.DefaultSessionManager"> 44 <property name="globalSessionTimeout" value="1800000"/> 45 <property name="deleteInvalidSessions" value="true"/> 46 <property name="sessionValidationSchedulerEnabled" value="true"/> 47 <property name="sessionValidationScheduler" ref="sessionValidationScheduler"/> 48 <property name="sessionDAO" ref="sessionDAO"/> 49 </bean> 50 <!-- 安全管理器 --> 51 <bean id="securityManager" class="org.apache.shiro.mgt.DefaultSecurityManager"> 52 <property name="realms"> 53 <list> 54 <ref bean="userRealm"/> 55 </list> 56 </property> 57 <property name="sessionManager" ref="sessionManager"/> 58 <property name="cacheManager" ref="cacheManager"/> 59 </bean> 60 <!-- 相当于调用SecurityUtils.setSecurityManager(securityManager) --> 61 <bean class="org.springframework.beans.factory.config.MethodInvokingFactoryBean"> 62 <property name="staticMethod" value="org.apache.shiro.SecurityUtils.setSecurityManager"/> 63 <property name="arguments" ref="securityManager"/> 64 </bean> 65 66 <!-- Shiro生命周期处理器--> 67 <bean id="lifecycleBeanPostProcessor" class="org.apache.shiro.spring.LifecycleBeanPostProcessor"/> 68 69 70 </beans>
5.spring-shiro-web.xml
提供了web应用的spring-shiro配置。
1 <!-- 缓存管理器 使用Ehcache实现 -->cacheManager ,涉及配置文件:ehcache.xml 2 <!-- 凭证匹配器 -->credentialsMatcher 3 <!-- Realm实现 -->userRealm 4 5 <!-- 会话ID生成器 -->sessionIdGenerator 6 <!-- 会话Cookie模板 -->sessionIdCookie 7 <!-- 会话DAO -->sessionDAO 8 <!-- 会话验证调度器 -->sessionValidationScheduler 9 <!-- 会话管理器 -->sessionManager 10 11 <!-- 安全管理器 -->securityManager 12 <!-- 基于Form表单的身份验证过滤器 -->formAuthenticationFilter 13 <!-- Shiro的Web过滤器 -->shiroFilter 14 <!-- Shiro生命周期处理器-->lifecycleBeanPostProcessor
1 <?xml version="1.0" encoding="UTF-8"?> 2 <beans xmlns="http://www.springframework.org/schema/beans" 3 xmlns:util="http://www.springframework.org/schema/util" 4 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 5 xsi:schemaLocation=" 6 http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd 7 http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util.xsd"> 8 9 <!-- 缓存管理器 使用Ehcache实现 --> 10 <bean id="cacheManager" class="org.apache.shiro.cache.ehcache.EhCacheManager"> 11 <property name="cacheManagerConfigFile" value="classpath:ehcache.xml"/> 12 </bean> 13 14 <!-- 凭证匹配器 --> 15 <bean id="credentialsMatcher" class="com.github.zhangkaitao.shiro.chapter12.credentials.RetryLimitHashedCredentialsMatcher"> 16 <constructor-arg ref="cacheManager"/> 17 <property name="hashAlgorithmName" value="md5"/> 18 <property name="hashIterations" value="2"/> 19 <property name="storedCredentialsHexEncoded" value="true"/> 20 </bean> 21 22 <!-- Realm实现 --> 23 <bean id="userRealm" class="com.github.zhangkaitao.shiro.chapter12.realm.UserRealm"> 24 <property name="userService" ref="userService"/> 25 <property name="credentialsMatcher" ref="credentialsMatcher"/> 26 <property name="cachingEnabled" value="true"/> 27 <property name="authenticationCachingEnabled" value="true"/> 28 <property name="authenticationCacheName" value="authenticationCache"/> 29 <property name="authorizationCachingEnabled" value="true"/> 30 <property name="authorizationCacheName" value="authorizationCache"/> 31 </bean> 32 33 <!-- 会话ID生成器 --> 34 <bean id="sessionIdGenerator" class="org.apache.shiro.session.mgt.eis.JavaUuidSessionIdGenerator"/> 35 36 <!-- 会话Cookie模板 --> 37 <bean id="sessionIdCookie" class="org.apache.shiro.web.servlet.SimpleCookie"> 38 <constructor-arg value="sid"/> 39 <property name="httpOnly" value="true"/> 40 <property name="maxAge" value="180000"/> 41 </bean> 42 43 <!-- 会话DAO --> 44 <bean id="sessionDAO" class="org.apache.shiro.session.mgt.eis.EnterpriseCacheSessionDAO"> 45 <property name="activeSessionsCacheName" value="shiro-activeSessionCache"/> 46 <property name="sessionIdGenerator" ref="sessionIdGenerator"/> 47 </bean> 48 49 <!-- 会话验证调度器 --> 50 <bean id="sessionValidationScheduler" class="org.apache.shiro.session.mgt.quartz.QuartzSessionValidationScheduler"> 51 <property name="sessionValidationInterval" value="1800000"/> 52 <property name="sessionManager" ref="sessionManager"/> 53 </bean> 54 55 <!-- 会话管理器 --> 56 <bean id="sessionManager" class="org.apache.shiro.web.session.mgt.DefaultWebSessionManager"> 57 <property name="globalSessionTimeout" value="1800000"/> 58 <property name="deleteInvalidSessions" value="true"/> 59 <property name="sessionValidationSchedulerEnabled" value="true"/> 60 <property name="sessionValidationScheduler" ref="sessionValidationScheduler"/> 61 <property name="sessionDAO" ref="sessionDAO"/> 62 <property name="sessionIdCookieEnabled" value="true"/> 63 <property name="sessionIdCookie" ref="sessionIdCookie"/> 64 </bean> 65 66 <!-- 安全管理器 --> 67 <bean id="securityManager" class="org.apache.shiro.web.mgt.DefaultWebSecurityManager"> 68 <property name="realm" ref="userRealm"/> 69 <property name="sessionManager" ref="sessionManager"/> 70 <property name="cacheManager" ref="cacheManager"/> 71 </bean> 72 73 <!-- 相当于调用SecurityUtils.setSecurityManager(securityManager) --> 74 <bean class="org.springframework.beans.factory.config.MethodInvokingFactoryBean"> 75 <property name="staticMethod" value="org.apache.shiro.SecurityUtils.setSecurityManager"/> 76 <property name="arguments" ref="securityManager"/> 77 </bean> 78 79 <!-- 基于Form表单的身份验证过滤器 --> 80 <bean id="formAuthenticationFilter" class="org.apache.shiro.web.filter.authc.FormAuthenticationFilter"> 81 <property name="usernameParam" value="username"/> 82 <property name="passwordParam" value="password"/> 83 <property name="loginUrl" value="/login.jsp"/> 84 </bean> 85 86 <!-- Shiro的Web过滤器 --> 87 <bean id="shiroFilter" class="org.apache.shiro.spring.web.ShiroFilterFactoryBean"> 88 <property name="securityManager" ref="securityManager"/> 89 <property name="loginUrl" value="/login.jsp"/> 90 <property name="unauthorizedUrl" value="/unauthorized.jsp"/> 91 <property name="filters"> 92 <util:map> 93 <entry key="authc" value-ref="formAuthenticationFilter"/> 94 </util:map> 95 </property> 96 <property name="filterChainDefinitions"> 97 <value> 98 /index.jsp = anon 99 /unauthorized.jsp = anon 100 /login.jsp = authc 101 /logout = logout 102 /** = user 103 </value> 104 </property> 105 </bean> 106 107 <!-- Shiro生命周期处理器--> 108 <bean id="lifecycleBeanPostProcessor" class="org.apache.shiro.spring.LifecycleBeanPostProcessor"/> 109 110 </beans>
6.ehcache.xml
1 <?xml version="1.0" encoding="UTF-8"?> 2 <ehcache name="shirocache"> 3 4 <diskStore path="java.io.tmpdir"/> 5 6 <!-- 登录记录缓存 锁定10分钟 --> 7 <cache name="passwordRetryCache" 8 maxEntriesLocalHeap="2000" 9 eternal="false" 10 timeToIdleSeconds="3600" 11 timeToLiveSeconds="0" 12 overflowToDisk="false" 13 statistics="true"> 14 </cache> 15 16 <cache name="authorizationCache" 17 maxEntriesLocalHeap="2000" 18 eternal="false" 19 timeToIdleSeconds="3600" 20 timeToLiveSeconds="0" 21 overflowToDisk="false" 22 statistics="true"> 23 </cache> 24 25 <cache name="authenticationCache" 26 maxEntriesLocalHeap="2000" 27 eternal="false" 28 timeToIdleSeconds="3600" 29 timeToLiveSeconds="0" 30 overflowToDisk="false" 31 statistics="true"> 32 </cache> 33 34 <cache name="shiro-activeSessionCache" 35 maxEntriesLocalHeap="2000" 36 eternal="false" 37 timeToIdleSeconds="3600" 38 timeToLiveSeconds="0" 39 overflowToDisk="false" 40 statistics="true"> 41 </cache> 42 43 </ehcache>
7.spring-mvc.xml
1 <?xml version="1.0" encoding="UTF-8"?> 2 <beans xmlns="http://www.springframework.org/schema/beans" 3 xmlns:context="http://www.springframework.org/schema/context" 4 xmlns:aop="http://www.springframework.org/schema/aop" 5 xmlns:mvc="http://www.springframework.org/schema/mvc" 6 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 7 xsi:schemaLocation=" 8 http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd 9 http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd 10 http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop.xsd 11 http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc.xsd"> 12 13 <context:component-scan base-package="com.github.zhangkaitao" use-default-filters="false"> 14 <context:include-filter type="annotation" expression="org.springframework.stereotype.Controller"/> 15 <context:include-filter type="annotation" expression="org.springframework.web.bind.annotation.ControllerAdvice"/> 16 </context:component-scan> 17 18 <aop:config proxy-target-class="true"></aop:config> 19 <bean class="org.apache.shiro.spring.security.interceptor.AuthorizationAttributeSourceAdvisor"> 20 <property name="securityManager" ref="securityManager"/> 21 </bean> 22 23 <mvc:annotation-driven/> 24 <mvc:view-controller path="/" view-name="index"/> 25 26 <!-- 默认的视图解析器 在上边的解析错误时使用 (默认使用html)- --> 27 <bean id="defaultViewResolver" class="org.springframework.web.servlet.view.InternalResourceViewResolver"> 28 <property name="viewClass" value="org.springframework.web.servlet.view.JstlView"/> 29 <property name="contentType" value="text/html"/> 30 <property name="prefix" value="/"/> 31 <property name="suffix" value=".jsp"/> 32 </bean> 33 34 <!-- 控制器异常处理 --> 35 <bean id="exceptionHandlerExceptionResolver" class="org.springframework.web.servlet.mvc.method.annotation.ExceptionHandlerExceptionResolver"> 36 </bean> 37 <bean class="com.github.zhangkaitao.shiro.chapter12.web.exception.DefaultExceptionHandler"/> 38 39 40 </beans>
注意,shiroFilter在web.xml、spring-shiro-web.xml中都出现了。他们之间的联系是什么?
DelegatingFilterProxy 会自动到 Spring 容器中查找名字为 shiroFilter 的 bean 并把 filter 请求交给它处理。
web.xml:
1 <filter> 2 <filter-name>shiroFilter</filter-name> 3 <filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class> 4 <async-supported>true</async-supported> 5 <init-param> 6 <param-name>targetFilterLifecycle</param-name> 7 <param-value>true</param-value> 8 </init-param> 9 </filter>
spring-shiro-web.xml:
1 <!-- Shiro的Web过滤器 --> 2 <bean id="shiroFilter" class="org.apache.shiro.spring.web.ShiroFilterFactoryBean"> 3 <property name="securityManager" ref="securityManager"/> 4 <property name="loginUrl" value="/login.jsp"/> 5 <property name="unauthorizedUrl" value="/unauthorized.jsp"/> 6 <property name="filters"> 7 <util:map> 8 <entry key="authc" value-ref="formAuthenticationFilter"/> 9 </util:map> 10 </property> 11 <property name="filterChainDefinitions"> 12 <value> 13 /index.jsp = anon 14 /unauthorized.jsp = anon 15 /login.jsp = authc 16 /logout = logout 17 /** = user 18 </value> 19 </property> 20 </bean>
如若内容造成侵权/违法违规/事实不符,请联系编程学习网邮箱:809451989@qq.com进行投诉反馈,一经查实,立即删除!
相关文章
- Java 中十进制和十六进制的相互转换
//十进制转化为十六进制,结果为C8。Integer.toHexString(200);//十六进制转化为十进制,结果140。Integer.parseInt("8C",16);...
2024/4/18 17:08:11 - ubuntu配置ntp服务器
一个多台机器构成系统,有时候会有时间同步的需求,比如应用服务器和数据库服务器,如果两则不一致的话,有时就会产生问题,所以需要一个时间同步的机制来保证每台机器的时间一致。 Network Time Protocol(NTP,网络时间协议)用于同步它所有客户端时钟的服务。NTP服务器将本地…...
2024/4/14 22:41:49 - 2018-2019-2 20189215 《网络攻防技术》第七周作业
教材《网络攻防技术》第七章学习 第7章 Windows操作系统安全攻防 7.1 Windows操作系统基本框架概述 windows基本结构分为运行于处理器特权模式的操作系统内核以及运行在处理器非特权模式的用户,即为内核态和用户态。 内核态:windows执行体、windows内核体、设备驱动程序、硬件…...
2024/4/18 4:43:09 - 小编教你怎样重装系统win7
很多朋友都在问怎样重装系统win7,其实这个方法是非常普遍的,基本上大家都懂得,但是无法避免有很多电脑新手没接触过这个方法,因此小编决定来教一教大家怎样重装系统win7。准备工作:1.一个4G及以上的U盘。2.系统之家PE迷你U盘启动制作工具3.Win7 GHO镜像文件重装步骤:1.将…...
2024/4/15 23:16:30 - 《跟我学Shiro》教程
历经三个月左右时间,《跟我学Shiro》系列教程已经完结,暂时没有需要补充的内容,因此生成PDF版供大家下载。最近项目比较紧,没有时间解答一些疑问,暂时无法回复一些问题,很抱歉,不过可以加群(334194438/348194195)一起讨论问题。教程作者:张开涛教程地址:https://www…...
2024/4/20 4:29:15 - how2j 的shiro教程初探
教程案例里的mysql连接器只支持mysql,不支持mariadb,如果用的不是mysql,创建连接时会报错。转载于:https://www.cnblogs.com/kinome/p/10413015.html...
2024/4/20 4:13:34 - 《网络攻防实践》第七周作业
教材学习总结 Windows操作系统的基本结构 Windows操作系统内核的基本模块 Windows执行体 Windows内核体 设备驱动程序 硬件抽象层Windows窗口与图形界面接口内核实现代码 Windows操作系统在用户态的代码模块 系统支持进程 环境子系统服务进程 服务进程 用户应用软件 核心子系统…...
2024/4/14 22:41:44 - 图像分割之Snake主动轮廓模型(Matlab代码)
示例演示如果在中文搜索的话,一般会找到《数字图像处理-图像分割:Snake主动轮廓模型 Matlab代码及运行结果》。里面有句代码,千万别用,否则出不来效果。(别问我怎么知道的) % 转化为双精度型 %I = im2double(I); 当然英文搜索的话,会在Matlab官网上找到《Snakes…...
2024/4/27 5:00:56 - 分享一款Win7下的IE6测试工具:IE6forWin7
我也是用IETester,觉得实在是不好用。原文链接:http://www.zi-han.net/developer/503.html做前端的,永远都摆脱不了IE6的噩梦,苦逼的的前端工程师同学都知道,目前,win7下没有一款比较靠谱的IE6测试工具,很多同学不得不选择IEtester这一类的调试工具开发,但是IEtester本…...
2024/4/15 9:47:09 - Linux网络编程——tcp并发服务器(多进程)
一、tcp并发服务器概述一个好的服务器,一般都是并发服务器(同一时刻可以响应多个客户端的请求)。并发服务器设计技术一般有:多进程服务器、多线程服务器、I/O复用服务器等。二、多进程并发服务器在 Linux 环境下多进程的应用很多,其中最主要的就是网络/客户服务器。多进程服…...
2024/4/14 22:00:39 - C#如何实现二进制、八进制、十进制与十六进制之间的相互转换?
在生活中,我们大多使用的是十进制,那么如何将十进制转换成其它进制的信息呢?以软件【进制转换器】为例。C#中,使用Convert.ToString方法可以将十进制转换成二进制、八进制和十六进制,使用Convert.ToInt64方法可以将二进制、八进制和十六进制转换成十进制。那么如何将二进制…...
2024/4/14 22:00:38 - Android Java byte数组 16进制与10进制之间转换
前段时间当好要做一个Ble 读写。其中就有进制转换。bytesToHex();//byte数据转化成16进制字符串static final char[] hexArray = "0123456789ABCDEF".toCharArray();private static String bytesToHex(byte[] bytes) {char[] hexChars = new char[bytes.length * 2];…...
2024/4/14 22:00:38 - Linux服务器时间设置及同步
1 手动设置date命令:date :查看当前时间,结果如下:Wed Feb 4 16:29:51 CST 2015date -s 16:30:00 :设置当前时间,结果如下:Wed Feb 4 16:30:00 CST 2015date -s "YYYY-MM-DD hh:mm[:ss]" 如date -s "2015-02-04 16:30:00"hwclock -w(将时间写入bio…...
2024/4/18 18:48:04 - 小米笔记本Air 13.3(第7代CPU平台驱动 指纹版)安装WIN7
1、为WIN7镜像集成USB3.0,NVME,等一系列新驱动首先用吧win7镜像引导进U盘,然后下载《WindowsImageTool》软件进行改造,改造方法如图:这个软件去技嘉官网下,在《主板-软件工具》里面,文件名叫《mb_utility_windowsimagetool》,看好主板芯片,选更新时间最晚那个版本。2、…...
2024/4/14 22:00:35 - Shiro教程--Authentication身份验证及JDBC Realm域(三)
http://shiro.apache.org/authentication.html******一 身份验证Authentication******通过上图需要了解的与元素:一 Subject认证主体所包含的主要信息1-Principals:身份(用户名,邮件,手机号码等,标识一个登陆主体身份)2-Credentials:凭证(密码,数字证书等)二 Realm&…...
2024/4/14 22:00:35 - Java写一条吃满屏幕的贪吃蛇(A*自动寻路算法和一些简单的策略) 二
上一篇文章介绍了一条贪吃蛇的简单实现,这一篇介绍贪吃蛇的自动寻路算法 ,说是自动寻路其实也就是一种遍历地图的算法,如果玩过游戏肯定知道游戏里面一般会有自动寻路功能,贪吃蛇的自动寻路算法也就是实现这个功能。下面慢慢介绍这种算法吧。 最开始,我没有在网上找资料…...
2024/4/18 1:34:01 - 【Shiro + Spring MVC整合】教程
1、准备Shiro的架包和spring 的架包2、项目的架构3、配置web.xml<?xml version="1.0" encoding="UTF-8"?> <web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2…...
2024/4/17 13:06:36 - Intelligent Transportation 目标跟踪算法
Intelligent Transportation 目标跟踪算法出自论文: A feature-based tracking algorithm for vehicles in intersections其它参考文献:最著名的目标跟踪算法 A real-time computer vision system for measuring traffic parametersKLT算法网址:http://www.ces.clemson.edu/~s…...
2024/4/14 22:41:41 - NTP 时间服务器实战
关于 NTP 服务器的基本概念: 时间服务器:NTP服务器 关于 NTP 服务器的基本安装搭建:NTP 服务器的安装与设定一 主机规划 二 前期准备 1 设置好时区 2 检查 NTP 是否安装 3 设置同步更新本地 hwclock 4 查看能提供服务的外部时间服务器 5 先使用 ntpdate 手动同步下时间三 修…...
2024/4/14 22:41:42 - php16进制转换为字符串
因项目需求对接一个java的接口 密匙是16进制。使用php内置函数:hex2bin$str = abc; $key = XXXXX; $res = (hash_hmac("sha1", $str, hex2bin($key), false));hash_hmac最后一个参数true输出原始二进制,false输出为小写16进制...
2024/4/16 13:17:05
最新文章
- XYCTF 2024
本博客仅为记录解题的过程! MISC game google识图 XYCTF{Papers Please} 熊博士 XYCTF{liu_ye_mei_you_xiao_jj} 疯狂大杂烩!九转功成 在远古时期,修仙过程被分为:炼气、筑基、结丹、元婴、化神、炼虚、合体、大乘、渡劫等九…...
2024/4/28 14:13:42 - 梯度消失和梯度爆炸的一些处理方法
在这里是记录一下梯度消失或梯度爆炸的一些处理技巧。全当学习总结了如有错误还请留言,在此感激不尽。 权重和梯度的更新公式如下: w w − η ⋅ ∇ w w w - \eta \cdot \nabla w ww−η⋅∇w 个人通俗的理解梯度消失就是网络模型在反向求导的时候出…...
2024/3/20 10:50:27 - 视觉循迹小车(旭日x3派、opencv)
基于旭日x3派的视觉循迹小车,未完全实现,参考:https://developer.horizon.cc/forumDetail/146176819622746404 效果硬件视觉循迹原理python代码 效果 硬件 1、旭日x3派(烧录好系统镜像) 2、USB摄像头 3、TB6612 4、小…...
2024/4/15 8:48:11 - 【超简单】基于PaddleSpeech搭建个人语音听写服务
一、【超简单】之基于PaddleSpeech搭建个人语音听写服务 1.需求分析 亲们,你们要写会议纪要嘛?亲们,你们要写会议纪要嘛?亲们,你们要写会议纪要嘛?当您面对成吨的会议录音,着急写会议纪要而不得不愚公移山、人海战术?听的头晕眼花,听的漏洞百出,听的怀疑人生,那么你…...
2024/4/26 14:59:02 - Kimi精选提示词,总结PPT内容
大家好,我是子云,最近真是觉得Kimi这个大模型,产品体验很棒,能力也是不错,感觉产品经理用心了。 发现一个Kimi 一个小技巧,可以学习到很多高级提示词。 Kimi输入框可以配置常用提示词,同时也可…...
2024/4/28 13:35:23 - 【外汇早评】美通胀数据走低,美元调整
原标题:【外汇早评】美通胀数据走低,美元调整昨日美国方面公布了新一期的核心PCE物价指数数据,同比增长1.6%,低于前值和预期值的1.7%,距离美联储的通胀目标2%继续走低,通胀压力较低,且此前美国一季度GDP初值中的消费部分下滑明显,因此市场对美联储后续更可能降息的政策…...
2024/4/28 13:52:11 - 【原油贵金属周评】原油多头拥挤,价格调整
原标题:【原油贵金属周评】原油多头拥挤,价格调整本周国际劳动节,我们喜迎四天假期,但是整个金融市场确实流动性充沛,大事频发,各个商品波动剧烈。美国方面,在本周四凌晨公布5月份的利率决议和新闻发布会,维持联邦基金利率在2.25%-2.50%不变,符合市场预期。同时美联储…...
2024/4/28 3:28:32 - 【外汇周评】靓丽非农不及疲软通胀影响
原标题:【外汇周评】靓丽非农不及疲软通胀影响在刚结束的周五,美国方面公布了新一期的非农就业数据,大幅好于前值和预期,新增就业重新回到20万以上。具体数据: 美国4月非农就业人口变动 26.3万人,预期 19万人,前值 19.6万人。 美国4月失业率 3.6%,预期 3.8%,前值 3…...
2024/4/26 23:05:52 - 【原油贵金属早评】库存继续增加,油价收跌
原标题:【原油贵金属早评】库存继续增加,油价收跌周三清晨公布美国当周API原油库存数据,上周原油库存增加281万桶至4.692亿桶,增幅超过预期的74.4万桶。且有消息人士称,沙特阿美据悉将于6月向亚洲炼油厂额外出售更多原油,印度炼油商预计将每日获得至多20万桶的额外原油供…...
2024/4/28 13:51:37 - 【外汇早评】日本央行会议纪要不改日元强势
原标题:【外汇早评】日本央行会议纪要不改日元强势近两日日元大幅走强与近期市场风险情绪上升,避险资金回流日元有关,也与前一段时间的美日贸易谈判给日本缓冲期,日本方面对汇率问题也避免继续贬值有关。虽然今日早间日本央行公布的利率会议纪要仍然是支持宽松政策,但这符…...
2024/4/27 17:58:04 - 【原油贵金属早评】欧佩克稳定市场,填补伊朗问题的影响
原标题:【原油贵金属早评】欧佩克稳定市场,填补伊朗问题的影响近日伊朗局势升温,导致市场担忧影响原油供给,油价试图反弹。此时OPEC表态稳定市场。据消息人士透露,沙特6月石油出口料将低于700万桶/日,沙特已经收到石油消费国提出的6月份扩大出口的“适度要求”,沙特将满…...
2024/4/27 14:22:49 - 【外汇早评】美欲与伊朗重谈协议
原标题:【外汇早评】美欲与伊朗重谈协议美国对伊朗的制裁遭到伊朗的抗议,昨日伊朗方面提出将部分退出伊核协议。而此行为又遭到欧洲方面对伊朗的谴责和警告,伊朗外长昨日回应称,欧洲国家履行它们的义务,伊核协议就能保证存续。据传闻伊朗的导弹已经对准了以色列和美国的航…...
2024/4/28 1:28:33 - 【原油贵金属早评】波动率飙升,市场情绪动荡
原标题:【原油贵金属早评】波动率飙升,市场情绪动荡因中美贸易谈判不安情绪影响,金融市场各资产品种出现明显的波动。随着美国与中方开启第十一轮谈判之际,美国按照既定计划向中国2000亿商品征收25%的关税,市场情绪有所平复,已经开始接受这一事实。虽然波动率-恐慌指数VI…...
2024/4/27 9:01:45 - 【原油贵金属周评】伊朗局势升温,黄金多头跃跃欲试
原标题:【原油贵金属周评】伊朗局势升温,黄金多头跃跃欲试美国和伊朗的局势继续升温,市场风险情绪上升,避险黄金有向上突破阻力的迹象。原油方面稍显平稳,近期美国和OPEC加大供给及市场需求回落的影响,伊朗局势并未推升油价走强。近期中美贸易谈判摩擦再度升级,美国对中…...
2024/4/27 17:59:30 - 【原油贵金属早评】市场情绪继续恶化,黄金上破
原标题:【原油贵金属早评】市场情绪继续恶化,黄金上破周初中国针对于美国加征关税的进行的反制措施引发市场情绪的大幅波动,人民币汇率出现大幅的贬值动能,金融市场受到非常明显的冲击。尤其是波动率起来之后,对于股市的表现尤其不安。隔夜美国股市出现明显的下行走势,这…...
2024/4/25 18:39:16 - 【外汇早评】美伊僵持,风险情绪继续升温
原标题:【外汇早评】美伊僵持,风险情绪继续升温昨日沙特两艘油轮再次发生爆炸事件,导致波斯湾局势进一步恶化,市场担忧美伊可能会出现摩擦生火,避险品种获得支撑,黄金和日元大幅走强。美指受中美贸易问题影响而在低位震荡。继5月12日,四艘商船在阿联酋领海附近的阿曼湾、…...
2024/4/28 1:34:08 - 【原油贵金属早评】贸易冲突导致需求低迷,油价弱势
原标题:【原油贵金属早评】贸易冲突导致需求低迷,油价弱势近日虽然伊朗局势升温,中东地区几起油船被袭击事件影响,但油价并未走高,而是出于调整结构中。由于市场预期局势失控的可能性较低,而中美贸易问题导致的全球经济衰退风险更大,需求会持续低迷,因此油价调整压力较…...
2024/4/26 19:03:37 - 氧生福地 玩美北湖(上)——为时光守候两千年
原标题:氧生福地 玩美北湖(上)——为时光守候两千年一次说走就走的旅行,只有一张高铁票的距离~ 所以,湖南郴州,我来了~ 从广州南站出发,一个半小时就到达郴州西站了。在动车上,同时改票的南风兄和我居然被分到了一个车厢,所以一路非常愉快地聊了过来。 挺好,最起…...
2024/4/28 1:22:35 - 氧生福地 玩美北湖(中)——永春梯田里的美与鲜
原标题:氧生福地 玩美北湖(中)——永春梯田里的美与鲜一觉醒来,因为大家太爱“美”照,在柳毅山庄去寻找龙女而错过了早餐时间。近十点,向导坏坏还是带着饥肠辘辘的我们去吃郴州最富有盛名的“鱼头粉”。说这是“十二分推荐”,到郴州必吃的美食之一。 哇塞!那个味美香甜…...
2024/4/25 18:39:14 - 氧生福地 玩美北湖(下)——奔跑吧骚年!
原标题:氧生福地 玩美北湖(下)——奔跑吧骚年!让我们红尘做伴 活得潇潇洒洒 策马奔腾共享人世繁华 对酒当歌唱出心中喜悦 轰轰烈烈把握青春年华 让我们红尘做伴 活得潇潇洒洒 策马奔腾共享人世繁华 对酒当歌唱出心中喜悦 轰轰烈烈把握青春年华 啊……啊……啊 两…...
2024/4/26 23:04:58 - 扒开伪装医用面膜,翻六倍价格宰客,小姐姐注意了!
原标题:扒开伪装医用面膜,翻六倍价格宰客,小姐姐注意了!扒开伪装医用面膜,翻六倍价格宰客!当行业里的某一品项火爆了,就会有很多商家蹭热度,装逼忽悠,最近火爆朋友圈的医用面膜,被沾上了污点,到底怎么回事呢? “比普通面膜安全、效果好!痘痘、痘印、敏感肌都能用…...
2024/4/27 23:24:42 - 「发现」铁皮石斛仙草之神奇功效用于医用面膜
原标题:「发现」铁皮石斛仙草之神奇功效用于医用面膜丽彦妆铁皮石斛医用面膜|石斛多糖无菌修护补水贴19大优势: 1、铁皮石斛:自唐宋以来,一直被列为皇室贡品,铁皮石斛生于海拔1600米的悬崖峭壁之上,繁殖力差,产量极低,所以古代仅供皇室、贵族享用 2、铁皮石斛自古民间…...
2024/4/28 5:48:52 - 丽彦妆\医用面膜\冷敷贴轻奢医学护肤引导者
原标题:丽彦妆\医用面膜\冷敷贴轻奢医学护肤引导者【公司简介】 广州华彬企业隶属香港华彬集团有限公司,专注美业21年,其旗下品牌: 「圣茵美」私密荷尔蒙抗衰,产后修复 「圣仪轩」私密荷尔蒙抗衰,产后修复 「花茵莳」私密荷尔蒙抗衰,产后修复 「丽彦妆」专注医学护…...
2024/4/26 19:46:12 - 广州械字号面膜生产厂家OEM/ODM4项须知!
原标题:广州械字号面膜生产厂家OEM/ODM4项须知!广州械字号面膜生产厂家OEM/ODM流程及注意事项解读: 械字号医用面膜,其实在我国并没有严格的定义,通常我们说的医美面膜指的应该是一种「医用敷料」,也就是说,医用面膜其实算作「医疗器械」的一种,又称「医用冷敷贴」。 …...
2024/4/27 11:43:08 - 械字号医用眼膜缓解用眼过度到底有无作用?
原标题:械字号医用眼膜缓解用眼过度到底有无作用?医用眼膜/械字号眼膜/医用冷敷眼贴 凝胶层为亲水高分子材料,含70%以上的水分。体表皮肤温度传导到本产品的凝胶层,热量被凝胶内水分子吸收,通过水分的蒸发带走大量的热量,可迅速地降低体表皮肤局部温度,减轻局部皮肤的灼…...
2024/4/27 8:32:30 - 配置失败还原请勿关闭计算机,电脑开机屏幕上面显示,配置失败还原更改 请勿关闭计算机 开不了机 这个问题怎么办...
解析如下:1、长按电脑电源键直至关机,然后再按一次电源健重启电脑,按F8健进入安全模式2、安全模式下进入Windows系统桌面后,按住“winR”打开运行窗口,输入“services.msc”打开服务设置3、在服务界面,选中…...
2022/11/19 21:17:18 - 错误使用 reshape要执行 RESHAPE,请勿更改元素数目。
%读入6幅图像(每一幅图像的大小是564*564) f1 imread(WashingtonDC_Band1_564.tif); subplot(3,2,1),imshow(f1); f2 imread(WashingtonDC_Band2_564.tif); subplot(3,2,2),imshow(f2); f3 imread(WashingtonDC_Band3_564.tif); subplot(3,2,3),imsho…...
2022/11/19 21:17:16 - 配置 已完成 请勿关闭计算机,win7系统关机提示“配置Windows Update已完成30%请勿关闭计算机...
win7系统关机提示“配置Windows Update已完成30%请勿关闭计算机”问题的解决方法在win7系统关机时如果有升级系统的或者其他需要会直接进入一个 等待界面,在等待界面中我们需要等待操作结束才能关机,虽然这比较麻烦,但是对系统进行配置和升级…...
2022/11/19 21:17:15 - 台式电脑显示配置100%请勿关闭计算机,“准备配置windows 请勿关闭计算机”的解决方法...
有不少用户在重装Win7系统或更新系统后会遇到“准备配置windows,请勿关闭计算机”的提示,要过很久才能进入系统,有的用户甚至几个小时也无法进入,下面就教大家这个问题的解决方法。第一种方法:我们首先在左下角的“开始…...
2022/11/19 21:17:14 - win7 正在配置 请勿关闭计算机,怎么办Win7开机显示正在配置Windows Update请勿关机...
置信有很多用户都跟小编一样遇到过这样的问题,电脑时发现开机屏幕显现“正在配置Windows Update,请勿关机”(如下图所示),而且还需求等大约5分钟才干进入系统。这是怎样回事呢?一切都是正常操作的,为什么开时机呈现“正…...
2022/11/19 21:17:13 - 准备配置windows 请勿关闭计算机 蓝屏,Win7开机总是出现提示“配置Windows请勿关机”...
Win7系统开机启动时总是出现“配置Windows请勿关机”的提示,没过几秒后电脑自动重启,每次开机都这样无法进入系统,此时碰到这种现象的用户就可以使用以下5种方法解决问题。方法一:开机按下F8,在出现的Windows高级启动选…...
2022/11/19 21:17:12 - 准备windows请勿关闭计算机要多久,windows10系统提示正在准备windows请勿关闭计算机怎么办...
有不少windows10系统用户反映说碰到这样一个情况,就是电脑提示正在准备windows请勿关闭计算机,碰到这样的问题该怎么解决呢,现在小编就给大家分享一下windows10系统提示正在准备windows请勿关闭计算机的具体第一种方法:1、2、依次…...
2022/11/19 21:17:11 - 配置 已完成 请勿关闭计算机,win7系统关机提示“配置Windows Update已完成30%请勿关闭计算机”的解决方法...
今天和大家分享一下win7系统重装了Win7旗舰版系统后,每次关机的时候桌面上都会显示一个“配置Windows Update的界面,提示请勿关闭计算机”,每次停留好几分钟才能正常关机,导致什么情况引起的呢?出现配置Windows Update…...
2022/11/19 21:17:10 - 电脑桌面一直是清理请关闭计算机,windows7一直卡在清理 请勿关闭计算机-win7清理请勿关机,win7配置更新35%不动...
只能是等着,别无他法。说是卡着如果你看硬盘灯应该在读写。如果从 Win 10 无法正常回滚,只能是考虑备份数据后重装系统了。解决来方案一:管理员运行cmd:net stop WuAuServcd %windir%ren SoftwareDistribution SDoldnet start WuA…...
2022/11/19 21:17:09 - 计算机配置更新不起,电脑提示“配置Windows Update请勿关闭计算机”怎么办?
原标题:电脑提示“配置Windows Update请勿关闭计算机”怎么办?win7系统中在开机与关闭的时候总是显示“配置windows update请勿关闭计算机”相信有不少朋友都曾遇到过一次两次还能忍但经常遇到就叫人感到心烦了遇到这种问题怎么办呢?一般的方…...
2022/11/19 21:17:08 - 计算机正在配置无法关机,关机提示 windows7 正在配置windows 请勿关闭计算机 ,然后等了一晚上也没有关掉。现在电脑无法正常关机...
关机提示 windows7 正在配置windows 请勿关闭计算机 ,然后等了一晚上也没有关掉。现在电脑无法正常关机以下文字资料是由(历史新知网www.lishixinzhi.com)小编为大家搜集整理后发布的内容,让我们赶快一起来看一下吧!关机提示 windows7 正在配…...
2022/11/19 21:17:05 - 钉钉提示请勿通过开发者调试模式_钉钉请勿通过开发者调试模式是真的吗好不好用...
钉钉请勿通过开发者调试模式是真的吗好不好用 更新时间:2020-04-20 22:24:19 浏览次数:729次 区域: 南阳 > 卧龙 列举网提醒您:为保障您的权益,请不要提前支付任何费用! 虚拟位置外设器!!轨迹模拟&虚拟位置外设神器 专业用于:钉钉,外勤365,红圈通,企业微信和…...
2022/11/19 21:17:05 - 配置失败还原请勿关闭计算机怎么办,win7系统出现“配置windows update失败 还原更改 请勿关闭计算机”,长时间没反应,无法进入系统的解决方案...
前几天班里有位学生电脑(windows 7系统)出问题了,具体表现是开机时一直停留在“配置windows update失败 还原更改 请勿关闭计算机”这个界面,长时间没反应,无法进入系统。这个问题原来帮其他同学也解决过,网上搜了不少资料&#x…...
2022/11/19 21:17:04 - 一个电脑无法关闭计算机你应该怎么办,电脑显示“清理请勿关闭计算机”怎么办?...
本文为你提供了3个有效解决电脑显示“清理请勿关闭计算机”问题的方法,并在最后教给你1种保护系统安全的好方法,一起来看看!电脑出现“清理请勿关闭计算机”在Windows 7(SP1)和Windows Server 2008 R2 SP1中,添加了1个新功能在“磁…...
2022/11/19 21:17:03 - 请勿关闭计算机还原更改要多久,电脑显示:配置windows更新失败,正在还原更改,请勿关闭计算机怎么办...
许多用户在长期不使用电脑的时候,开启电脑发现电脑显示:配置windows更新失败,正在还原更改,请勿关闭计算机。。.这要怎么办呢?下面小编就带着大家一起看看吧!如果能够正常进入系统,建议您暂时移…...
2022/11/19 21:17:02 - 还原更改请勿关闭计算机 要多久,配置windows update失败 还原更改 请勿关闭计算机,电脑开机后一直显示以...
配置windows update失败 还原更改 请勿关闭计算机,电脑开机后一直显示以以下文字资料是由(历史新知网www.lishixinzhi.com)小编为大家搜集整理后发布的内容,让我们赶快一起来看一下吧!配置windows update失败 还原更改 请勿关闭计算机&#x…...
2022/11/19 21:17:01 - 电脑配置中请勿关闭计算机怎么办,准备配置windows请勿关闭计算机一直显示怎么办【图解】...
不知道大家有没有遇到过这样的一个问题,就是我们的win7系统在关机的时候,总是喜欢显示“准备配置windows,请勿关机”这样的一个页面,没有什么大碍,但是如果一直等着的话就要两个小时甚至更久都关不了机,非常…...
2022/11/19 21:17:00 - 正在准备配置请勿关闭计算机,正在准备配置windows请勿关闭计算机时间长了解决教程...
当电脑出现正在准备配置windows请勿关闭计算机时,一般是您正对windows进行升级,但是这个要是长时间没有反应,我们不能再傻等下去了。可能是电脑出了别的问题了,来看看教程的说法。正在准备配置windows请勿关闭计算机时间长了方法一…...
2022/11/19 21:16:59 - 配置失败还原请勿关闭计算机,配置Windows Update失败,还原更改请勿关闭计算机...
我们使用电脑的过程中有时会遇到这种情况,当我们打开电脑之后,发现一直停留在一个界面:“配置Windows Update失败,还原更改请勿关闭计算机”,等了许久还是无法进入系统。如果我们遇到此类问题应该如何解决呢࿰…...
2022/11/19 21:16:58 - 如何在iPhone上关闭“请勿打扰”
Apple’s “Do Not Disturb While Driving” is a potentially lifesaving iPhone feature, but it doesn’t always turn on automatically at the appropriate time. For example, you might be a passenger in a moving car, but your iPhone may think you’re the one dri…...
2022/11/19 21:16:57