1.pom.xml配置

1.1<build>标签中配置<plugins>和<resources>,即插件和资源文件

1.2 <properties>标签中配置自定义的标签,可以在<dependency>中取出

1.3<dependencies>中配置各依赖包,统一管理

2.创建项目用到的包

1.1web层一般用到model,dao,controller,service,utils,security

1.2创建webapp下面的静态资源存放目录,如images,js,WEB-INF目录下的views

3.resources下创建资源文件

1.1先创建数据库的配置文件

##JDBC Global Setting
jdbc.driver=com.mysql.jdbc.Driver
jdbc.url=jdbc:mysql://127.0.0.1:3306/demo?useUnicode=true&characterEncoding=utf-8
jdbc.username=root
jdbc.password=root ##DataSource Global Setting #配置初始化大小、最小、最大
ds.initialSize=
ds.minIdle=
ds.maxActive= #配置获取连接等待超时的时间
ds.maxWait= #配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位是毫秒
ds.timeBetweenEvictionRunsMillis= #配置一个连接在池中最小生存的时间,单位是毫秒
ds.minEvictableIdleTimeMillis=

1.2log4j日志的配置文件

# DEBUG,INFO,WARN,ERROR,FATAL
LOG_LEVEL=INFO log4j.rootLogger=${LOG_LEVEL},CONSOLE,FILE log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender
log4j.appender.CONSOLE.Encoding=utf-
log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout
#log4j.appender.CONSOLE.layout.ConversionPattern=[%-5p] %d{yyyy-MM-dd HH:mm:ss} %C{}@(%F:%L):%m%n
log4j.appender.CONSOLE.layout.ConversionPattern=[%-5p] %d{yyyy-MM-dd HH:mm:ss} %C{}@(%F:%L):%m%n log4j.appender.FILE=org.apache.log4j.DailyRollingFileAppender
log4j.appender.FILE.File=${catalina.base}/logs/ssm.log
log4j.appender.FILE.Encoding=utf-
log4j.appender.FILE.DatePattern='.'yyyy-MM-dd
log4j.appender.FILE.layout=org.apache.log4j.PatternLayout
#log4j.appender.FILE.layout=org.apache.log4j.HTMLLayout
log4j.appender.FILE.layout.ConversionPattern=[%-5p] %d{yyyy-MM-dd HH\:mm\:ss} %C{}@(%F\:%L)\:%m%n

1.3创建applicationContext.xml文件(spring的配置文件)

  1.3.1 创建过程:(1)管理包下的注解(2)引入数据库配置文件(3)配置数据源dataSource(4)mybatis文件配置,扫描所有mapper接口,sqlsessionFactory需要配置属性dataSource,mybatis配置文件地址,mapper接口地址

         (5)spring和mybatis整合,扫描所有dao,需要属性配置,dao地址,sqlsessionFactory(6)事务管理器,需要dataSource(7)事务通知,对哪些方法进行了哪些事务管理(8)事务的aop管理,需要切点与通知

         (9)配置spring的cglib代理(10)开启事务的注解(11)配置spring的cache注解,需要缓存管理器,缓存管理器引用缓存管理器工厂,工厂指向ehcache.xml文件

  1.3.2代码:

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:context="http://www.springframework.org/schema/context"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:aop="http://www.springframework.org/schema/aop"
xmlns:tx="http://www.springframework.org/schema/tx" xmlns:p="http://www.springframework.org/schema/p"
xmlns:util="http://www.springframework.org/schema/util" xmlns:jdbc="http://www.springframework.org/schema/jdbc"
xmlns:cache="http://www.springframework.org/schema/cache"
xsi:schemaLocation="
http://www.springframework.org/schema/context
http://www.springframework.org/schema/context/spring-context.xsd
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/tx
http://www.springframework.org/schema/tx/spring-tx.xsd
http://www.springframework.org/schema/jdbc
http://www.springframework.org/schema/jdbc/spring-jdbc.xsd
http://www.springframework.org/schema/cache
http://www.springframework.org/schema/cache/spring-cache.xsd
http://www.springframework.org/schema/aop
http://www.springframework.org/schema/aop/spring-aop.xsd
http://www.springframework.org/schema/util
http://www.springframework.org/schema/util/spring-util.xsd">
<!--自动扫描sj包,将带有注解的类纳入spring管理 在xml配置了这个标签后,spring可以自动去扫描base-pack下面或者子包下面的java文件,
如果扫描到有@Component @Controller@Service等这些注解的类,则把这些类注册为bean-->
<context:component-scan base-package="com.demo"></context:component-scan> <!--引入配置文件-->
<bean id="propertyConfigurer" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
<property name="locations">
<list>
<value>classpath*:application.properties</value>
</list>
</property>
</bean> <!--配置数据源-->
<bean id="dataSource" class="com.alibaba.druid.pool.DruidDataSource" init-method="init" destroy-method="close">
<property name="url" value="${jdbc.url}"/>
<property name="username" value="${jdbc.username}"/>
<property name="password" value="${jdbc.password}"/> <!-- 配置初始化大小、最小、最大 -->
<property name="initialSize" value="${ds.initialSize}"/>
<property name="minIdle" value="${ds.minIdle}"/>
<property name="maxActive" value="${ds.maxActive}"/> <!-- 配置获取连接等待超时的时间 -->
<property name="maxWait" value="${ds.maxWait}"/> <!-- 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位是毫秒 -->
<property name="timeBetweenEvictionRunsMillis" value="${ds.timeBetweenEvictionRunsMillis}"/> <!-- 配置一个连接在池中最小生存的时间,单位是毫秒 -->
<property name="minEvictableIdleTimeMillis" value="${ds.minEvictableIdleTimeMillis}"/> <property name="validationQuery" value="SELECT 'x'"/>
<property name="testWhileIdle" value="true"/>
<property name="testOnBorrow" value="false"/>
<property name="testOnReturn" value="false"/> <!-- 打开PSCache,并且指定每个连接上PSCache的大小 -->
<property name="poolPreparedStatements" value="false"/>
<property name="maxPoolPreparedStatementPerConnectionSize" value=""/> <!-- 配置监控统计拦截的filters -->
<property name="filters" value="stat"/>
</bean>
<!--mybatis扫描mapper接口-->
<bean id="sqlSessionFactory" class="org.mybatis.spring.SqlSessionFactoryBean" p:dataSource-ref="dataSource"
p:configLocation="classpath:mybatis-config.xml" p:mapperLocations="classpath:com/demo/web/dao/*.xml">
</bean> <!--spring与mybatis整合配置,扫描所有dao-->
<bean class="org.mybatis.spring.mapper.MapperScannerConfigurer" p:basePackage="com.demo.web.dao"
p:sqlSessionFactoryBeanName="sqlSessionFactory"></bean>
<!--事务配置-->
<bean id="transactionManager" class="org.springframework.jdbc.datasource.DataSourceTransactionManager" p:dataSource-ref="dataSource" /> <!--事务通知-->
<tx:advice id="txActive" transaction-manager="transactionManager">
<tx:attributes>
<!-- 对insert,update,delete 开头的方法进行事务管理,只要有异常就回滚 -->
<tx:method name="insert*" propagation="REQUIRED" rollback-for="java.lang.Throwable"/>
<tx:method name="update*" propagation="REQUIRED" rollback-for="java.lang.Throwable"/>
<tx:method name="delete*" propagation="REQUIRED" rollback-for="java.lang.Throwable"/>
<!-- select,count开头的方法,开启只读,提高数据库访问性能 -->
<tx:method name="select*" read-only="true"/>
<tx:method name="count*" read-only="true"/>
<!-- 对其他方法 使用默认的事务管理 -->
<tx:method name="*"/>
</tx:attributes>
</tx:advice>
<!--aop-->
<aop:config>
<aop:pointcut id="serviceMethods" expression="execution(* com.demo.web.service..*(..))"/>
<aop:advisor advice-ref="txActive" pointcut-ref="serviceMethods"></aop:advisor>
</aop:config>
<!-- 配置使Spring采用CGLIB代理 -->
<aop:aspectj-autoproxy proxy-target-class="true"/>
<!--事务的注解支持-->
<tx:annotation-driven transaction-manager="transactionManager"/>
<!--Cache配置-->
<cache:annotation-driven cache-manager="cacheManager"/>
<bean id="ehCacheManagerFactory" class="org.springframework.cache.ehcache.EhCacheManagerFactoryBean" p:configLocation="classpath:ehcache.xml"/>
<bean id="cacheManager" class="org.springframework.cache.ehcache.EhCacheCacheManager" p:cacheManager-ref="ehCacheManagerFactory"/> </beans>

1.4创建mybatis-config.xml文件,并配置

  1.4.1基本需要:与spring整合后只需一个空框架即可,不用加任何配置,也对mybatis有其他配置,如typeAliases别名,settings设置等

  1.4.2代码:

<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE configuration
PUBLIC "-//mybatis.org//DTD Config 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-config.dtd">
<configuration>
<properties>
<property name="dialectClass" value="com.demo.core.feature.orm.dialect.MySql5Dialect"/>
</properties> <!-- 配置mybatis的缓存,延迟加载等等一系列属性 -->
<settings> <!-- 全局映射器启用缓存 -->
<setting name="cacheEnabled" value="true"/> <!-- 查询时,关闭关联对象即时加载以提高性能 -->
<setting name="lazyLoadingEnabled" value="true"/> <!-- 对于未知的SQL查询,允许返回不同的结果集以达到通用的效果 -->
<setting name="multipleResultSetsEnabled" value="true"/> <!-- 允许使用列标签代替列名 -->
<setting name="useColumnLabel" value="true"/> <!-- 不允许使用自定义的主键值(比如由程序生成的UUID 32位编码作为键值),数据表的PK生成策略将被覆盖 -->
<setting name="useGeneratedKeys" value="false"/> <!-- 给予被嵌套的resultMap以字段-属性的映射支持 FULL,PARTIAL -->
<setting name="autoMappingBehavior" value="PARTIAL"/> <!-- 对于批量更新操作缓存SQL以提高性能 BATCH,SIMPLE -->
<!-- <setting name="defaultExecutorType" value="BATCH" /> --> <!-- 数据库超过25000秒仍未响应则超时 -->
<!-- <setting name="defaultStatementTimeout" value="" /> --> <!-- Allows using RowBounds on nested statements -->
<setting name="safeRowBoundsEnabled" value="false"/> <!-- Enables automatic mapping from classic database column names A_COLUMN to camel case classic Java property names aColumn. -->
<setting name="mapUnderscoreToCamelCase" value="true"/> <!-- MyBatis uses local cache to prevent circular references and speed up repeated nested queries. By default (SESSION) all queries executed during a session are cached. If localCacheScope=STATEMENT
local session will be used just for statement execution, no data will be shared between two different calls to the same SqlSession. -->
<setting name="localCacheScope" value="SESSION"/> <!-- Specifies the JDBC type for null values when no specific JDBC type was provided for the parameter. Some drivers require specifying the column JDBC type but others work with generic values
like NULL, VARCHAR or OTHER. -->
<setting name="jdbcTypeForNull" value="OTHER"/> <!-- Specifies which Object's methods trigger a lazy load -->
<setting name="lazyLoadTriggerMethods" value="equals,clone,hashCode,toString"/> <!-- 设置关联对象加载的形态,此处为按需加载字段(加载字段由SQL指 定),不会加载关联表的所有字段,以提高性能 -->
<setting name="aggressiveLazyLoading" value="false"/> </settings>
<!--写了别名就可以在mapper.xml文件中直接写类名-->
<typeAliases>
<package name="com.demo.web.model"></package>
</typeAliases> <plugins>
<plugin interceptor="com.demo.core.feature.orm.mybatis.PaginationResultSetHandlerInterceptor"/>
<plugin interceptor="com.demo.core.feature.orm.mybatis.PaginationStatementHandlerInterceptor"/>
</plugins> </configuration>

1.5配置ehcache.xml文件,缓存管理配置

<?xml version="1.0" encoding="UTF-8"?>
<ehcache updateCheck="false" name="txswx-ehcache">
<!--
磁盘存储:将缓存中暂时不使用的对象,转移到硬盘,类似于Windows系统的虚拟内存
path:指定在硬盘上存储对象的路径
-->
<diskStore path="java.io.tmpdir"/>
<!--
defaultCache:默认的缓存配置信息,如果不加特殊说明,则所有对象按照此配置项处理
maxElementsInMemory:设置了缓存的上限,最多存储多少个记录对象
eternal:代表对象是否永不过期
timeToIdleSeconds:最大的发呆时间
timeToLiveSeconds:最大的存活时间
overflowToDisk:是否允许对象被写入到磁盘
-->
<defaultCache maxEntriesLocalHeap="" eternal="true" timeToIdleSeconds="" timeToLiveSeconds=""
overflowToDisk="true" maxEntriesLocalDisk=""/>
</ehcache>

1.6创建springmvc.xml

  1.6.1基础配置创建过程:(1)把controller层的注解纳入管理(2)模型视图前后缀管理(3)springmvc上传文件配置(4)整合shiro框架配置

  1.6.2代码:(较为复杂的配置,不是基础配置)

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:aop="http://www.springframework.org/schema/aop"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:mvc="http://www.springframework.org/schema/mvc"
xmlns:tx="http://www.springframework.org/schema/tx"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:p="http://www.springframework.org/schema/p"
xsi:schemaLocation="http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd
http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc.xsd
http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx.xsd">
<!--controller层注入-->
<context:component-scan base-package="com.demo.web.controller"/>
<!-- 指定自己定义的validator -->
<mvc:annotation-driven validator="validator"/>
<!-- 以下 validator ConversionService 在使用 mvc:annotation-driven 会 自动注册 -->
<bean id="validator" class="org.springframework.validation.beanvalidation.LocalValidatorFactoryBean">
<property name="providerClass" value="org.hibernate.validator.HibernateValidator"/>
<!-- 如果不加默认到 使用classpath下的 ValidationMessages.properties -->
<property name="validationMessageSource" ref="messageSource"/>
</bean> <!-- 国际化的消息资源文件(本系统中主要用于显示/错误消息定制) -->
<bean id="messageSource" class="org.springframework.context.support.ReloadableResourceBundleMessageSource">
<property name="basenames">
<list>
<!-- 在web环境中一定要定位到classpath 否则默认到当前web应用下找 -->
<value>classpath:messages</value>
<value>classpath:org/hibernate/validator/ValidationMessages</value>
</list>
</property>
<property name="useCodeAsDefaultMessage" value="false"/>
<property name="defaultEncoding" value="UTF-8"/>
<property name="cacheSeconds" value=""/>
</bean>
<!--配置拦截器-->
<mvc:interceptors>
<bean class="org.springframework.web.servlet.i18n.LocaleChangeInterceptor"/>
</mvc:interceptors> <bean id="localeResolver" class="org.springframework.web.servlet.i18n.CookieLocaleResolver">
<property name="defaultLocale" value="zh_CN"/>
</bean>
<!--支持返回json(避免IE在ajax请求时,返回json出现下载 )-->
<bean class="org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerAdapter">
<property name="messageConverters">
<list>
<ref bean="mappingJacksonHttpMessageConverter"/>
</list>
</property>
</bean>
<bean id="mappingJacksonHttpMessageConverter"
class="org.springframework.http.converter.json.MappingJacksonHttpMessageConverter">
<property name="supportedMediaTypes">
<list>
<value>text/plain;charset=UTF-</value>
<value>application/json;charset=UTF-</value>
</list>
</property>
</bean>
<!--模型视图增加前后缀-->
<bean id="viewResolver" class="org.springframework.web.servlet.view.InternalResourceViewResolver" p:prefix="/WEB-INF/views/" p:suffix=".jsp"/>
<!--springMvc上传文件-->
<bean id="multipartResolver" class="org.springframework.web.multipart.commons.CommonsMultipartResolver">
<property name="defaultEncoding" value="utf-8"/>
<property name="maxUploadSize" value=""/>
<property name="maxInMemorySize" value=""/>
</bean>
<!--启用shiro授权注解方式-->
<aop:config proxy-target-class="true"></aop:config>
<bean class="org.apache.shiro.spring.security.interceptor.AuthorizationAttributeSourceAdvisor">
<property name="securityManager" ref="securityManager"/>
</bean>
</beans>

1.7application_shiro.xml文件配置

  1.7.1创建过程:(1)shiro过滤器配置(包括安全管理器,登录页面,登录成功页面,没有访问权限页面,权限设置)(2)会话DAO(3)会话管理器,需要会话DAO(4)缓存管理器,需要缓存管理配置文件路径(5)reamls配置,需要自定义的realm类(6)安全管理器,需要reamls配置(7)shiro生命周期处理器

  1.7.2代码:

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:util="http://www.springframework.org/schema/util"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util.xsd">
<description>apache shiro配置</description>
<bean id="shiroFilter" class="org.apache.shiro.spring.web.ShiroFilterFactoryBean">
<!--配置securityManager 安全管理器-->
<property name="securityManager" ref="securityManager"/>
<property name="loginUrl" value="/page/login.shtml"/>
<property name="successUrl" value="/index.shtml"/>
<property name="unauthorizedUrl" value="/page/401.shtml"/>
<property name="filterChainDefinitions">
<value>
<!-- 静态资源允许访问 -->
/app/** = anon
/assets/** = anon
<!-- 登录页允许访问 -->
/user/login = anon
<!-- 其他资源需要认证 -->
/** = authc
</value>
</property>
</bean>
<!--缓存管理器-->
<bean id="shiroEhcacheManager" class="org.apache.shiro.cache.ehcache.EhCacheManager">
<property name="cacheManagerConfigFile" value="classpath:ehcache-shiro.xml"/>
</bean> <!--会话DAO-->
<bean id="sessionDAO" class="org.apache.shiro.session.mgt.eis.MemorySessionDAO"/> <!--会话管理器-->
<bean id="sessionManager" class="org.apache.shiro.web.session.mgt.DefaultWebSessionManager">
<property name="sessionDAO" ref="sessionDAO"/>
</bean> <!--登录规则-->
<bean id="securityRealm" class="com.cjw.web.security.SecurityRealm"/> <bean id="securityManager" class="org.apache.shiro.web.mgt.DefaultWebSecurityManager">
<property name="realms">
<list>
<ref bean = "securityRealm"/>
</list>
</property>
</bean>
<!-- Shiro生命周期处理器 -->
<bean id="lifecycleBeanPostProcessor" class="org.apache.shiro.spring.LifecycleBeanPostProcessor"/> </beans>

1.8ehcache-shiro.xml配置

<ehcache updateCheck="false" name="shiroCache">

    <defaultCache
maxElementsInMemory=""
eternal="false"
timeToIdleSeconds=""
timeToLiveSeconds=""
overflowToDisk="false"
diskPersistent="false"
diskExpiryThreadIntervalSeconds=""
/>
</ehcache>

1.9 web.xml配置

  1.9.1创建过程:(1)spring文件初始化配置(2)spring上下文监听器配置(3)spring编码过滤器配置(4)log4j初始化配置(5)log4j监听器配置(6)shiro过滤器配置(7)前端控制器配置(8)错误页面配置


												

ssm框架配置过程的更多相关文章

  1. SSM框架整合过程总结

    -----------------------siwuxie095                                 SSM 框架整合过程总结         1.导入相关 jar 包( ...

  2. ssm框架整合-过程总结(第二次周总结)

    距离上次写博客已经有4.5天的时间了. 这次写博客目的是总结一下项目开始到现在,过程中遇到的问题.和学到的知识.经验. 初略总结下自己从中学到的: Spring :在学习中被反复强调的Ioc(反转控制 ...

  3. ssh框架配置过程

    1.pom.xml配置依赖 <?xml version="1.0" encoding="UTF-8"?> <project xmlns=&qu ...

  4. 基于SSM框架配置多数据源

    项目基于ssm + maven,通过注解可以实现自动切换数据源. 一.pom.xml <?xml version="1.0" encoding="UTF-8&quo ...

  5. SSM框架搭建过程

    引入依赖的jar包(pom.xml) a. <!--Spring SpringMVC相关-->  spring-webmvc b. <!--Spring事务-->  sprin ...

  6. ssm框架整合-过程总结(第三次周总结)

    本周主要是完成前端界面和后端的整合. 犹豫前后端的工作完成程度不一致,只实现了部分整合. 登录界面. 可能自己最近没有把重心放在短学期的项目上,导致我们工作的总体进度都要比别慢. 虽然我们只是三个人的 ...

  7. pageoffice实现网页打开编辑保存word文档(基于SSM框架)

    pageoffice是一款网页集成word.excel...等office工具 并不免费,但可以试用练习 SSM框架搭建过程就省略了 注意:由于谷歌/火狐升级,不支持插件嵌入,建议使用POBrowse ...

  8. 01-电子商城项目介绍及ssm框架搭建

    1.B2C电商项目功能及架构 1.1功能列表 1.2系统架构(soa架构) 2.后台管理系统工程搭建及测试 ypMall,ypMall-manager-web ypMall为父项目,管理子项目的jar ...

  9. SSM框架中的注解,配置和控制器相关笔记

    常规SSM实例 探索SSM理论的前提,应该是在对框架基础的运作方式有一定了解,以下是个人Android后台项目,用SSM框架快速搭建,以下是代码,主要 观察结构. 代码结构: model实体类 Ida ...

随机推荐

  1. python 网络爬虫介绍

    一.网络爬虫相关概念 网络爬虫介绍 我们都知道,当前我们所处的时代是大数据的时代,在大数据时代,要进行数据分析,首先要有数据源,而学习爬虫,可以让我们获取更多的数据源,并且这些数据源可以按我们的目的进 ...

  2. 分享一下个人学PS的过程

    得知Photoshop这款软件是在上大学的时候,2010年.学校学生会的科技部纳新,要求新人会PPT.word.Excel和Photoshop.当时有一个Photoshop大神,成为了学生会科技部的主 ...

  3. 使用C#创建WCF服务控制台应用程序

    本文属于原创,转载请注明出处,谢谢! 一.开发环境 操作系统:Windows 10 开发环境:VS2015 编程语言:C# IIS版本:10.0.0.0 二.添加WCF服务.Internet Info ...

  4. iOSPush自动隐藏tabbar

    只需要在UITabBarController添加控制器的时候调用YZNav初始化,就可以实现tabbar的自动隐藏了. 直接上github地址:https://github.com/YouZhiZhe ...

  5. KVM虚拟机管理——虚拟机创建和操作系统安装

    1. 概述2. 交互式安装2.1 图形化-本地安装2.1.1 图形化本地CDROM安装2.2.2 图形化本地镜像安装2.2 命令行-本地安装2.2.1 命令行CDROM安装2.3 图形化-网络安装2. ...

  6. shell实现压缩多个文件

    Linux环境下写一个脚本 从键盘让用户输入几个文件,脚本能够将此几个文件归档压缩成一个文件: 1.首先介绍一下case语句格式 case SWITCH in value1) statement .. ...

  7. LintCode——Pour Water

    Pour Water: We are given an elevation map, heights[i] representing the height of the terrain at that ...

  8. PAT-1010 Radix

    1010 Radix (25 分) Given a pair of positive integers, for example, 6 and 110, can this equation 6 = 1 ...

  9. Bitcoin区块验证

    目录 区块的生成 区块的验证链接 验证过程 Merkle Tree结构 区块的生成 矿工在挖矿前要组建区块 将coinbase交易打包进区块 将交易池中高优先级的交易打包进区块 优先级 = 交易的额度 ...

  10. PHPMyWind5.4存储XSS(CVE-2017-12984)

    0x0 环境 操作机:xp   192.168.110.128 目标:win2003    192.168.110.133 目标cms:PHPMyWind5.4 0x11 漏洞介绍 允许恶意访问者在客 ...