Commit 374b7bdf authored by gao's avatar gao

监控系统(微信消息推送)

1.0 签名服务器监控
2.0 可信平台监控
3.0 服务状态监控
parent f2f06587
<component name="ArtifactManager">
<artifact name="LegalPersonMonitor:jar">
<output-path>$PROJECT_DIR$/out/artifacts/LegalPersonMonitor_jar</output-path>
<root id="root">
<element id="directory" name="lib">
<element id="library" level="project" name="Maven: com.fasterxml.jackson.core:jackson-annotations:2.9.0" />
<element id="library" level="project" name="Maven: com.fasterxml.jackson.core:jackson-core:2.9.2" />
<element id="library" level="project" name="commons-httpclient-3.1 (2)" />
<element id="library" level="project" name="Maven: com.fasterxml.jackson.core:jackson-databind:2.9.2" />
<element id="library" level="project" name="Maven: commons-beanutils:commons-beanutils:1.8.0" />
<element id="library" level="project" name="Maven: commons-codec:commons-codec:1.9" />
<element id="library" level="project" name="Maven: commons-collections:commons-collections:3.2.1" />
<element id="library" level="project" name="Maven: commons-lang:commons-lang:2.5" />
<element id="library" level="project" name="Maven: commons-logging:commons-logging:1.1.1" />
<element id="library" level="project" name="Maven: net.sf.ezmorph:ezmorph:1.0.6" />
<element id="library" level="project" name="Maven: net.sf.json-lib:json-lib:jdk15:2.4" />
<element id="library" level="project" name="Maven: org.apache.httpcomponents:httpclient:4.5.3" />
<element id="library" level="project" name="Maven: org.apache.httpcomponents:httpcore:4.4.6" />
<element id="library" level="project" name="Maven: org.springframework:spring-aop:4.3.10.RELEASE" />
<element id="library" level="project" name="Maven: org.springframework:spring-beans:4.3.10.RELEASE" />
<element id="library" level="project" name="Maven: org.springframework:spring-context-support:4.3.10.RELEASE" />
<element id="library" level="project" name="Maven: org.springframework:spring-context:4.3.10.RELEASE" />
<element id="library" level="project" name="Maven: org.springframework:spring-core:4.3.10.RELEASE" />
<element id="library" level="project" name="Maven: org.springframework:spring-expression:4.3.10.RELEASE" />
<element id="library" level="project" name="Spring-4.3.13.RELEASE" />
<element id="archive" name="LegalPersonMonitor.jar">
<element id="directory" name="META-INF">
<element id="file-copy" path="$PROJECT_DIR$/META-INF/MANIFEST.MF" />
</element>
<element id="module-output" name="LegalPersonMonitor" />
</element>
<element id="directory" name="config">
<element id="file-copy" path="$PROJECT_DIR$/config/cssconfig.properties" />
</element>
</element>
</root>
</artifact>
</component>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="CompilerConfiguration">
<annotationProcessing>
<profile name="Maven default annotation processors profile" enabled="true">
<sourceOutputDir name="target/generated-sources/annotations" />
<sourceTestOutputDir name="target/generated-test-sources/test-annotations" />
<outputRelativeToContentRoot value="true" />
<module name="LegalPersonMonitor" />
</profile>
</annotationProcessing>
<bytecodeTargetLevel>
<module name="LegalPersonMonitor" target="1.8" />
</bytecodeTargetLevel>
</component>
</project>
\ No newline at end of file
<component name="InspectionProjectProfileManager">
<profile version="1.0">
<option name="myName" value="Project Default" />
<inspection_tool class="AliAccessStaticViaInstance" enabled="false" level="BLOCKER" enabled_by_default="false" />
<inspection_tool class="AliAccessToNonThreadSafeStaticFieldFromInstance" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AliArrayNamingShouldHaveBracket" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AliControlFlowStatementWithoutBraces" enabled="false" level="BLOCKER" enabled_by_default="false" />
<inspection_tool class="AliDeprecation" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AliEqualsAvoidNull" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AliLongLiteralsEndingWithLowercaseL" enabled="false" level="BLOCKER" enabled_by_default="false" />
<inspection_tool class="AliMissingOverrideAnnotation" enabled="false" level="BLOCKER" enabled_by_default="false" />
<inspection_tool class="AliWrapperTypeEquality" enabled="false" level="BLOCKER" enabled_by_default="false" />
<inspection_tool class="AlibabaAbstractClassShouldStartWithAbstractNaming" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AlibabaAbstractMethodOrInterfaceMethodMustUseJavadoc" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaAvoidApacheBeanUtilsCopy" enabled="false" level="BLOCKER" enabled_by_default="false" />
<inspection_tool class="AlibabaAvoidCommentBehindStatement" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaAvoidComplexCondition" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaAvoidConcurrentCompetitionRandom" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaAvoidManuallyCreateThread" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AlibabaAvoidMissUseOfMathRandom" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaAvoidNewDateGetTime" enabled="false" level="BLOCKER" enabled_by_default="false" />
<inspection_tool class="AlibabaAvoidPatternCompileInMethod" enabled="false" level="BLOCKER" enabled_by_default="false" />
<inspection_tool class="AlibabaAvoidReturnInFinally" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AlibabaAvoidStartWithDollarAndUnderLineNaming" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AlibabaAvoidUseTimer" enabled="false" level="BLOCKER" enabled_by_default="false" />
<inspection_tool class="AlibabaBooleanPropertyShouldNotStartWithIs" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AlibabaClassCastExceptionWithSubListToArrayList" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AlibabaClassCastExceptionWithToArray" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AlibabaClassMustHaveAuthor" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaClassNamingShouldBeCamel" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaCollectionInitShouldAssignCapacity" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaCommentsMustBeJavadocFormat" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaConcurrentExceptionWithModifyOriginSubList" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AlibabaConstantFieldShouldBeUpperCase" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AlibabaCountDownShouldInFinally" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaDontModifyInForeachCircle" enabled="false" level="BLOCKER" enabled_by_default="false" />
<inspection_tool class="AlibabaEnumConstantsMustHaveComment" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AlibabaExceptionClassShouldEndWithException" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AlibabaIbatisMethodQueryForList" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaLowerCamelCaseVariableNaming" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AlibabaMethodReturnWrapperType" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaPackageNaming" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaPojoMustOverrideToString" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaPojoMustUsePrimitiveField" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaPojoNoDefaultValue" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaRemoveCommentedCode" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaServiceOrDaoClassShouldEndWithImpl" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AlibabaStringConcat" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaSwitchStatement" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AlibabaTestClassShouldEndWithTestNaming" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaThreadLocalShouldRemove" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AlibabaThreadPoolCreation" enabled="false" level="BLOCKER" enabled_by_default="false" />
<inspection_tool class="AlibabaThreadShouldSetName" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AlibabaTransactionMustHaveRollback" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaUndefineMagicConstant" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="AlibabaUnsupportedExceptionWithModifyAsList" enabled="false" level="CRITICAL" enabled_by_default="false" />
<inspection_tool class="AlibabaUseQuietReferenceNotation" enabled="false" level="MAJOR" enabled_by_default="false" />
<inspection_tool class="JavaDoc" enabled="true" level="WARNING" enabled_by_default="true">
<option name="TOP_LEVEL_CLASS_OPTIONS">
<value>
<option name="ACCESS_JAVADOC_REQUIRED_FOR" value="none" />
<option name="REQUIRED_TAGS" value="" />
</value>
</option>
<option name="INNER_CLASS_OPTIONS">
<value>
<option name="ACCESS_JAVADOC_REQUIRED_FOR" value="none" />
<option name="REQUIRED_TAGS" value="" />
</value>
</option>
<option name="METHOD_OPTIONS">
<value>
<option name="ACCESS_JAVADOC_REQUIRED_FOR" value="none" />
<option name="REQUIRED_TAGS" value="@return@param@throws or @exception" />
</value>
</option>
<option name="FIELD_OPTIONS">
<value>
<option name="ACCESS_JAVADOC_REQUIRED_FOR" value="none" />
<option name="REQUIRED_TAGS" value="" />
</value>
</option>
<option name="IGNORE_DEPRECATED" value="false" />
<option name="IGNORE_JAVADOC_PERIOD" value="true" />
<option name="IGNORE_DUPLICATED_THROWS" value="false" />
<option name="IGNORE_POINT_TO_ITSELF" value="false" />
<option name="myAdditionalJavadocTags" value="date" />
</inspection_tool>
<inspection_tool class="MapOrSetKeyShouldOverrideHashCodeEquals" enabled="false" level="CRITICAL" enabled_by_default="false" />
</profile>
</component>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="JUnitGeneratorProjectSettings">
<option name="outputFilePattern" value="${SOURCEPATH}/JunitTest/${PACKAGE}/${FILENAME}" />
<option name="vmTemplates">
<map>
<entry key="JUnit 3" value="######################################################################################## &#10;## &#10;## Available variables: &#10;## $entryList.methodList - List of method composites &#10;## $entryList.privateMethodList - List of private method composites &#10;## $entryList.fieldList - ArrayList of class scope field names &#10;## $entryList.className - class name &#10;## $entryList.packageName - package name &#10;## $today - Todays date in MM/dd/yyyy format &#10;## &#10;## MethodComposite variables: &#10;## $method.name - Method Name &#10;## $method.signature - Full method signature in String form &#10;## $method.reflectionCode - list of strings representing commented out reflection code to access method (Private Methods) &#10;## $method.paramNames - List of Strings representing the method's parameters' names &#10;## $method.paramClasses - List of Strings representing the method's parameters' classes &#10;## &#10;## You can configure the output class name using &quot;testClass&quot; variable below. &#10;## Here are some examples: &#10;## Test${entry.ClassName} - will produce TestSomeClass &#10;## ${entry.className}Test - will produce SomeClassTest &#10;## &#10;######################################################################################## &#10;## &#10;#macro (cap $strIn)$strIn.valueOf($strIn.charAt(0)).toUpperCase()$strIn.substring(1)#end &#10;## Iterate through the list and generate testcase for every entry. &#10;#foreach ($entry in $entryList) &#10;#set( $testClass=&quot;${entry.className}Test&quot;) &#10;## &#10;package test.$entry.packageName; &#10;&#10;import junit.framework.Test; &#10;import junit.framework.TestSuite; &#10;import junit.framework.TestCase; &#10;&#10;/** &#10;* ${entry.className} Tester. &#10;* &#10;* @author &lt;Authors name&gt; &#10;* @since &lt;pre&gt;$today&lt;/pre&gt; &#10;* @version 1.0 &#10;*/ &#10;public class $testClass extends TestCase { &#10;public $testClass(String name) { &#10;super(name); &#10;} &#10;&#10;public void setUp() throws Exception { &#10;super.setUp(); &#10;} &#10;&#10;public void tearDown() throws Exception { &#10;super.tearDown(); &#10;} &#10;&#10;#foreach($method in $entry.methodList) &#10;/** &#10;* &#10;* Method: $method.signature &#10;* &#10;*/ &#10;public void test#cap(${method.name})() throws Exception { &#10;//TODO: Test goes here... &#10;} &#10;&#10;#end &#10;&#10;#foreach($method in $entry.privateMethodList) &#10;/** &#10;* &#10;* Method: $method.signature &#10;* &#10;*/ &#10;public void test#cap(${method.name})() throws Exception { &#10;//TODO: Test goes here... &#10;#foreach($string in $method.reflectionCode) &#10;$string &#10;#end &#10;} &#10;&#10;#end &#10;&#10;public static Test suite() { &#10;return new TestSuite(${testClass}.class); &#10;} &#10;} &#10;#end" />
<entry key="JUnit 4" value="######################################################################################## &#10;## &#10;## Available variables: &#10;## $entryList.methodList - List of method composites &#10;## $entryList.privateMethodList - List of private method composites &#10;## $entryList.fieldList - ArrayList of class scope field names &#10;## $entryList.className - class name &#10;## $entryList.packageName - package name &#10;## $today - Todays date in MM/dd/yyyy format &#10;## &#10;## MethodComposite variables: &#10;## $method.name - Method Name &#10;## $method.signature - Full method signature in String form &#10;## $method.reflectionCode - list of strings representing commented out reflection code to access method (Private Methods) &#10;## $method.paramNames - List of Strings representing the method's parameters' names &#10;## $method.paramClasses - List of Strings representing the method's parameters' classes &#10;## &#10;## You can configure the output class name using &quot;testClass&quot; variable below. &#10;## Here are some examples: &#10;## Test${entry.ClassName} - will produce TestSomeClass &#10;## ${entry.className}Test - will produce SomeClassTest &#10;## &#10;######################################################################################## &#10;## &#10;#macro (cap $strIn)$strIn.valueOf($strIn.charAt(0)).toUpperCase()$strIn.substring(1)#end &#10;## Iterate through the list and generate testcase for every entry. &#10;#foreach ($entry in $entryList) &#10;#set( $testClass=&quot;${entry.className}Test&quot;) &#10;## &#10;package JunitTest.$entry.packageName; &#10;&#10;import org.junit.Test; &#10;import org.junit.Before; &#10;import org.junit.After; &#10;&#10;/** &#10;* ${entry.className} Tester. &#10;* &#10;* @author Gaoxiang &#10;* @since &lt;pre&gt;$date&lt;/pre&gt; &#10;* @version 1.0 &#10;*/ &#10;public class $testClass { &#10;&#10;@Before&#10;public void before() throws Exception { &#10;} &#10;&#10;@After&#10;public void after() throws Exception { &#10;} &#10;&#10;#foreach($method in $entry.methodList) &#10;/** &#10;* &#10;* Method: $method.signature &#10;* &#10;*/ &#10;@Test&#10;public void test#cap(${method.name})() throws Exception { &#10;//TODO: Test goes here... &#10;} &#10;&#10;#end &#10;&#10;#foreach($method in $entry.privateMethodList) &#10;/** &#10;* &#10;* Method: $method.signature &#10;* &#10;*/ &#10;@Test&#10;public void test#cap(${method.name})() throws Exception { &#10;//TODO: Test goes here... &#10;#foreach($string in $method.reflectionCode) &#10;$string &#10;#end &#10;} &#10;&#10;#end &#10;} &#10;#end" />
</map>
</option>
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="KotlinCommonCompilerArguments">
<option name="languageVersion" value="1.1" />
<option name="apiVersion" value="1.1" />
</component>
</project>
\ No newline at end of file
<component name="libraryTable">
<library name="Maven: com.fasterxml.jackson.core:jackson-annotations:2.9.0">
<CLASSES>
<root url="jar://D:/Work/com/fasterxml/jackson/core/jackson-annotations/2.9.0/jackson-annotations-2.9.0.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://D:/Work/com/fasterxml/jackson/core/jackson-annotations/2.9.0/jackson-annotations-2.9.0-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://D:/Work/com/fasterxml/jackson/core/jackson-annotations/2.9.0/jackson-annotations-2.9.0-sources.jar!/" />
</SOURCES>
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Maven: com.fasterxml.jackson.core:jackson-core:2.9.2">
<CLASSES>
<root url="jar://D:/Work/com/fasterxml/jackson/core/jackson-core/2.9.2/jackson-core-2.9.2.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://D:/Work/com/fasterxml/jackson/core/jackson-core/2.9.2/jackson-core-2.9.2-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://D:/Work/com/fasterxml/jackson/core/jackson-core/2.9.2/jackson-core-2.9.2-sources.jar!/" />
</SOURCES>
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Maven: com.fasterxml.jackson.core:jackson-databind:2.9.2">
<CLASSES>
<root url="jar://D:/Work/com/fasterxml/jackson/core/jackson-databind/2.9.2/jackson-databind-2.9.2.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://D:/Work/com/fasterxml/jackson/core/jackson-databind/2.9.2/jackson-databind-2.9.2-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://D:/Work/com/fasterxml/jackson/core/jackson-databind/2.9.2/jackson-databind-2.9.2-sources.jar!/" />
</SOURCES>
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Maven: commons-beanutils:commons-beanutils:1.8.0">
<CLASSES>
<root url="jar://D:/Work/commons-beanutils/commons-beanutils/1.8.0/commons-beanutils-1.8.0.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://D:/Work/commons-beanutils/commons-beanutils/1.8.0/commons-beanutils-1.8.0-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://D:/Work/commons-beanutils/commons-beanutils/1.8.0/commons-beanutils-1.8.0-sources.jar!/" />
</SOURCES>
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Maven: commons-codec:commons-codec:1.9">
<CLASSES>
<root url="jar://D:/Work/commons-codec/commons-codec/1.9/commons-codec-1.9.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://D:/Work/commons-codec/commons-codec/1.9/commons-codec-1.9-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://D:/Work/commons-codec/commons-codec/1.9/commons-codec-1.9-sources.jar!/" />
</SOURCES>
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Maven: commons-collections:commons-collections:3.2.1">
<CLASSES>
<root url="jar://D:/Work/commons-collections/commons-collections/3.2.1/commons-collections-3.2.1.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://D:/Work/commons-collections/commons-collections/3.2.1/commons-collections-3.2.1-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://D:/Work/commons-collections/commons-collections/3.2.1/commons-collections-3.2.1-sources.jar!/" />
</SOURCES>
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Maven: commons-lang:commons-lang:2.5">
<CLASSES>
<root url="jar://D:/Work/commons-lang/commons-lang/2.5/commons-lang-2.5.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://D:/Work/commons-lang/commons-lang/2.5/commons-lang-2.5-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://D:/Work/commons-lang/commons-lang/2.5/commons-lang-2.5-sources.jar!/" />
</SOURCES>
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Maven: commons-logging:commons-logging:1.1.1">
<CLASSES>
<root url="jar://D:/Work/commons-logging/commons-logging/1.1.1/commons-logging-1.1.1.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://D:/Work/commons-logging/commons-logging/1.1.1/commons-logging-1.1.1-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://D:/Work/commons-logging/commons-logging/1.1.1/commons-logging-1.1.1-sources.jar!/" />
</SOURCES>
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Maven: net.sf.ezmorph:ezmorph:1.0.6">
<CLASSES>
<root url="jar://D:/Work/net/sf/ezmorph/ezmorph/1.0.6/ezmorph-1.0.6.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://D:/Work/net/sf/ezmorph/ezmorph/1.0.6/ezmorph-1.0.6-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://D:/Work/net/sf/ezmorph/ezmorph/1.0.6/ezmorph-1.0.6-sources.jar!/" />
</SOURCES>
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Maven: net.sf.json-lib:json-lib:jdk15:2.4">
<CLASSES>
<root url="jar://D:/Work/net/sf/json-lib/json-lib/2.4/json-lib-2.4-jdk15.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://D:/Work/net/sf/json-lib/json-lib/2.4/json-lib-2.4-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://D:/Work/net/sf/json-lib/json-lib/2.4/json-lib-2.4-sources.jar!/" />
</SOURCES>
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Maven: org.apache.httpcomponents:httpclient:4.5.3">
<CLASSES>
<root url="jar://D:/Work/org/apache/httpcomponents/httpclient/4.5.3/httpclient-4.5.3.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://D:/Work/org/apache/httpcomponents/httpclient/4.5.3/httpclient-4.5.3-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://D:/Work/org/apache/httpcomponents/httpclient/4.5.3/httpclient-4.5.3-sources.jar!/" />
</SOURCES>
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Maven: org.apache.httpcomponents:httpcore:4.4.6">
<CLASSES>
<root url="jar://D:/Work/org/apache/httpcomponents/httpcore/4.4.6/httpcore-4.4.6.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://D:/Work/org/apache/httpcomponents/httpcore/4.4.6/httpcore-4.4.6-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://D:/Work/org/apache/httpcomponents/httpcore/4.4.6/httpcore-4.4.6-sources.jar!/" />
</SOURCES>
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Maven: org.springframework:spring-aop:4.3.10.RELEASE">
<CLASSES>
<root url="jar://D:/Work/org/springframework/spring-aop/4.3.10.RELEASE/spring-aop-4.3.10.RELEASE.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://D:/Work/org/springframework/spring-aop/4.3.10.RELEASE/spring-aop-4.3.10.RELEASE-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://D:/Work/org/springframework/spring-aop/4.3.10.RELEASE/spring-aop-4.3.10.RELEASE-sources.jar!/" />
</SOURCES>
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Maven: org.springframework:spring-beans:4.3.10.RELEASE">
<CLASSES>
<root url="jar://D:/Work/org/springframework/spring-beans/4.3.10.RELEASE/spring-beans-4.3.10.RELEASE.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://D:/Work/org/springframework/spring-beans/4.3.10.RELEASE/spring-beans-4.3.10.RELEASE-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://D:/Work/org/springframework/spring-beans/4.3.10.RELEASE/spring-beans-4.3.10.RELEASE-sources.jar!/" />
</SOURCES>
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Maven: org.springframework:spring-context:4.3.10.RELEASE">
<CLASSES>
<root url="jar://D:/Work/org/springframework/spring-context/4.3.10.RELEASE/spring-context-4.3.10.RELEASE.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://D:/Work/org/springframework/spring-context/4.3.10.RELEASE/spring-context-4.3.10.RELEASE-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://D:/Work/org/springframework/spring-context/4.3.10.RELEASE/spring-context-4.3.10.RELEASE-sources.jar!/" />
</SOURCES>
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Maven: org.springframework:spring-context-support:4.3.10.RELEASE">
<CLASSES>
<root url="jar://D:/Work/org/springframework/spring-context-support/4.3.10.RELEASE/spring-context-support-4.3.10.RELEASE.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://D:/Work/org/springframework/spring-context-support/4.3.10.RELEASE/spring-context-support-4.3.10.RELEASE-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://D:/Work/org/springframework/spring-context-support/4.3.10.RELEASE/spring-context-support-4.3.10.RELEASE-sources.jar!/" />
</SOURCES>
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Maven: org.springframework:spring-core:4.3.10.RELEASE">
<CLASSES>
<root url="jar://D:/Work/org/springframework/spring-core/4.3.10.RELEASE/spring-core-4.3.10.RELEASE.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://D:/Work/org/springframework/spring-core/4.3.10.RELEASE/spring-core-4.3.10.RELEASE-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://D:/Work/org/springframework/spring-core/4.3.10.RELEASE/spring-core-4.3.10.RELEASE-sources.jar!/" />
</SOURCES>
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Maven: org.springframework:spring-expression:4.3.10.RELEASE">
<CLASSES>
<root url="jar://D:/Work/org/springframework/spring-expression/4.3.10.RELEASE/spring-expression-4.3.10.RELEASE.jar!/" />
</CLASSES>
<JAVADOC>
<root url="jar://D:/Work/org/springframework/spring-expression/4.3.10.RELEASE/spring-expression-4.3.10.RELEASE-javadoc.jar!/" />
</JAVADOC>
<SOURCES>
<root url="jar://D:/Work/org/springframework/spring-expression/4.3.10.RELEASE/spring-expression-4.3.10.RELEASE-sources.jar!/" />
</SOURCES>
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="Spring-4.3.13.RELEASE" type="spring">
<properties version="4.3.13.RELEASE" />
<CLASSES>
<root url="jar://$PROJECT_DIR$/lib/spring-aspects-4.3.13.RELEASE.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/spring-context-support-4.3.13.RELEASE.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/spring-context-4.3.13.RELEASE.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/spring-core-4.3.13.RELEASE.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/spring-expression-4.3.13.RELEASE.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/spring-beans-4.3.13.RELEASE.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/spring-instrument-4.3.13.RELEASE.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/spring-instrument-tomcat-4.3.13.RELEASE.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/spring-jms-4.3.13.RELEASE.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/spring-jdbc-4.3.13.RELEASE.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/spring-messaging-4.3.13.RELEASE.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/spring-oxm-4.3.13.RELEASE.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/spring-test-4.3.13.RELEASE.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/spring-orm-4.3.13.RELEASE.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/spring-tx-4.3.13.RELEASE.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/commons-logging-1.2.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/aopalliance-1.0.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/spring-aop-4.3.13.RELEASE.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES />
</library>
</component>
\ No newline at end of file
<component name="libraryTable">
<library name="commons-httpclient-3.1 (2)">
<CLASSES>
<root url="jar://$PROJECT_DIR$/lib/commons-httpclient-3.1.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/commons-logging-1.1.1.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/jit-pkitool-2.3.0.25-beta2.jar!/" />
<root url="jar://$PROJECT_DIR$/lib/jit-pkivstk-jdk15-1.0.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES />
</library>
</component>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="MavenProjectsManager">
<option name="originalFiles">
<list>
<option value="$PROJECT_DIR$/pom.xml" />
</list>
</option>
</component>
<component name="ProjectRootManager">
<output url="file://$PROJECT_DIR$/out" />
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/LegalPersonMonitor.iml" filepath="$PROJECT_DIR$/LegalPersonMonitor.iml" />
</modules>
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="SmartFoxProjectConfig">
<option name="projectInspectionClosed" value="true" />
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="Palette2">
<group name="Swing">
<item class="com.intellij.uiDesigner.HSpacer" tooltip-text="Horizontal Spacer" icon="/com/intellij/uiDesigner/icons/hspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
<default-constraints vsize-policy="1" hsize-policy="6" anchor="0" fill="1" />
</item>
<item class="com.intellij.uiDesigner.VSpacer" tooltip-text="Vertical Spacer" icon="/com/intellij/uiDesigner/icons/vspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
<default-constraints vsize-policy="6" hsize-policy="1" anchor="0" fill="2" />
</item>
<item class="javax.swing.JPanel" icon="/com/intellij/uiDesigner/icons/panel.png" removable="false" auto-create-binding="false" can-attach-label="false">
<default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3" />
</item>
<item class="javax.swing.JScrollPane" icon="/com/intellij/uiDesigner/icons/scrollPane.png" removable="false" auto-create-binding="false" can-attach-label="true">
<default-constraints vsize-policy="7" hsize-policy="7" anchor="0" fill="3" />
</item>
<item class="javax.swing.JButton" icon="/com/intellij/uiDesigner/icons/button.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="0" hsize-policy="3" anchor="0" fill="1" />
<initial-values>
<property name="text" value="Button" />
</initial-values>
</item>
<item class="javax.swing.JRadioButton" icon="/com/intellij/uiDesigner/icons/radioButton.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
<initial-values>
<property name="text" value="RadioButton" />
</initial-values>
</item>
<item class="javax.swing.JCheckBox" icon="/com/intellij/uiDesigner/icons/checkBox.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
<initial-values>
<property name="text" value="CheckBox" />
</initial-values>
</item>
<item class="javax.swing.JLabel" icon="/com/intellij/uiDesigner/icons/label.png" removable="false" auto-create-binding="false" can-attach-label="false">
<default-constraints vsize-policy="0" hsize-policy="0" anchor="8" fill="0" />
<initial-values>
<property name="text" value="Label" />
</initial-values>
</item>
<item class="javax.swing.JTextField" icon="/com/intellij/uiDesigner/icons/textField.png" removable="false" auto-create-binding="true" can-attach-label="true">
<default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
<preferred-size width="150" height="-1" />
</default-constraints>
</item>
<item class="javax.swing.JPasswordField" icon="/com/intellij/uiDesigner/icons/passwordField.png" removable="false" auto-create-binding="true" can-attach-label="true">
<default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
<preferred-size width="150" height="-1" />
</default-constraints>
</item>
<item class="javax.swing.JFormattedTextField" icon="/com/intellij/uiDesigner/icons/formattedTextField.png" removable="false" auto-create-binding="true" can-attach-label="true">
<default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
<preferred-size width="150" height="-1" />
</default-constraints>
</item>
<item class="javax.swing.JTextArea" icon="/com/intellij/uiDesigner/icons/textArea.png" removable="false" auto-create-binding="true" can-attach-label="true">
<default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
<preferred-size width="150" height="50" />
</default-constraints>
</item>
<item class="javax.swing.JTextPane" icon="/com/intellij/uiDesigner/icons/textPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
<default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
<preferred-size width="150" height="50" />
</default-constraints>
</item>
<item class="javax.swing.JEditorPane" icon="/com/intellij/uiDesigner/icons/editorPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
<default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
<preferred-size width="150" height="50" />
</default-constraints>
</item>
<item class="javax.swing.JComboBox" icon="/com/intellij/uiDesigner/icons/comboBox.png" removable="false" auto-create-binding="true" can-attach-label="true">
<default-constraints vsize-policy="0" hsize-policy="2" anchor="8" fill="1" />
</item>
<item class="javax.swing.JTable" icon="/com/intellij/uiDesigner/icons/table.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
<preferred-size width="150" height="50" />
</default-constraints>
</item>
<item class="javax.swing.JList" icon="/com/intellij/uiDesigner/icons/list.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="6" hsize-policy="2" anchor="0" fill="3">
<preferred-size width="150" height="50" />
</default-constraints>
</item>
<item class="javax.swing.JTree" icon="/com/intellij/uiDesigner/icons/tree.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
<preferred-size width="150" height="50" />
</default-constraints>
</item>
<item class="javax.swing.JTabbedPane" icon="/com/intellij/uiDesigner/icons/tabbedPane.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
<preferred-size width="200" height="200" />
</default-constraints>
</item>
<item class="javax.swing.JSplitPane" icon="/com/intellij/uiDesigner/icons/splitPane.png" removable="false" auto-create-binding="false" can-attach-label="false">
<default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
<preferred-size width="200" height="200" />
</default-constraints>
</item>
<item class="javax.swing.JSpinner" icon="/com/intellij/uiDesigner/icons/spinner.png" removable="false" auto-create-binding="true" can-attach-label="true">
<default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
</item>
<item class="javax.swing.JSlider" icon="/com/intellij/uiDesigner/icons/slider.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
</item>
<item class="javax.swing.JSeparator" icon="/com/intellij/uiDesigner/icons/separator.png" removable="false" auto-create-binding="false" can-attach-label="false">
<default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3" />
</item>
<item class="javax.swing.JProgressBar" icon="/com/intellij/uiDesigner/icons/progressbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1" />
</item>
<item class="javax.swing.JToolBar" icon="/com/intellij/uiDesigner/icons/toolbar.png" removable="false" auto-create-binding="false" can-attach-label="false">
<default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1">
<preferred-size width="-1" height="20" />
</default-constraints>
</item>
<item class="javax.swing.JToolBar$Separator" icon="/com/intellij/uiDesigner/icons/toolbarSeparator.png" removable="false" auto-create-binding="false" can-attach-label="false">
<default-constraints vsize-policy="0" hsize-policy="0" anchor="0" fill="1" />
</item>
<item class="javax.swing.JScrollBar" icon="/com/intellij/uiDesigner/icons/scrollbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
<default-constraints vsize-policy="6" hsize-policy="0" anchor="0" fill="2" />
</item>
</group>
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="" vcs="Git" />
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<module type="JAVA_MODULE" version="4">
<component name="NewModuleRootManager" inherit-compiler-output="true">
<exclude-output />
<module org.jetbrains.idea.maven.project.MavenProjectsManager.isMavenModule="true" type="JAVA_MODULE" version="4">
<component name="FacetManager">
<facet type="Spring" name="Spring">
<configuration>
<fileset id="fileset" name="Spring Application Context" removed="false">
<file>file://$MODULE_DIR$/src/main/resources/applicationContext.xml</file>
</fileset>
</configuration>
</facet>
</component>
<component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_8">
<output url="file://$MODULE_DIR$/target/classes" />
<output-test url="file://$MODULE_DIR$/target/test-classes" />
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/main/java" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/main/resources" type="java-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/test/java" isTestSource="true" />
<excludeFolder url="file://$MODULE_DIR$/target" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="jdk" jdkName="1.8" jdkType="JavaSDK" />
<orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="library" name="commons-httpclient-3.1 (2)" level="project" />
<orderEntry type="library" name="Spring-4.3.13.RELEASE" level="project" />
<orderEntry type="library" name="Maven: com.fasterxml.jackson.core:jackson-databind:2.9.2" level="project" />
<orderEntry type="library" name="Maven: com.fasterxml.jackson.core:jackson-annotations:2.9.0" level="project" />
<orderEntry type="library" name="Maven: com.fasterxml.jackson.core:jackson-core:2.9.2" level="project" />
<orderEntry type="library" name="Maven: net.sf.json-lib:json-lib:jdk15:2.4" level="project" />
<orderEntry type="library" name="Maven: commons-beanutils:commons-beanutils:1.8.0" level="project" />
<orderEntry type="library" name="Maven: commons-collections:commons-collections:3.2.1" level="project" />
<orderEntry type="library" name="Maven: commons-lang:commons-lang:2.5" level="project" />
<orderEntry type="library" name="Maven: commons-logging:commons-logging:1.1.1" level="project" />
<orderEntry type="library" name="Maven: net.sf.ezmorph:ezmorph:1.0.6" level="project" />
<orderEntry type="library" name="Maven: org.apache.httpcomponents:httpclient:4.5.3" level="project" />
<orderEntry type="library" name="Maven: org.apache.httpcomponents:httpcore:4.4.6" level="project" />
<orderEntry type="library" name="Maven: commons-codec:commons-codec:1.9" level="project" />
<orderEntry type="library" name="Maven: org.springframework:spring-core:4.3.10.RELEASE" level="project" />
<orderEntry type="library" name="Maven: org.springframework:spring-context-support:4.3.10.RELEASE" level="project" />
<orderEntry type="library" name="Maven: org.springframework:spring-beans:4.3.10.RELEASE" level="project" />
<orderEntry type="library" name="Maven: org.springframework:spring-context:4.3.10.RELEASE" level="project" />
<orderEntry type="library" name="Maven: org.springframework:spring-aop:4.3.10.RELEASE" level="project" />
<orderEntry type="library" name="Maven: org.springframework:spring-expression:4.3.10.RELEASE" level="project" />
</component>
</module>
\ No newline at end of file
ServerURL=http://192.168.0.110:8000/signserver/service/xml
#ServerURL=http\://192.168.1.13\:8000/signserver/service/xml
#ServerURL=http://192.168.253.126:8000/signserver/service/xml
#ServerURL=http://172.16.40.123:8000/signserver/service/xml
DigestAlg=sm3
#Encrypt Algorithm: des3/scb2
EncAlg=sm4
CertBaseInfo = version;issuerdn;subjectdn;serialnumber;notbefore;notafter
TSACertBaseInfo = issuerdn;subjectdn;serialnumber;signedTime;signedTSA;signedTimeByMS
CertExtendInfo =
AppID=
CertAlias =
BaseInfo =digestalg;digestdata;plaindata;dscert
SendMsgFormat=0
HashActionPosition=0
PrintLog=false
#console/file/log4j ####log4j not implement
logTarget=console
logFilePath=/temp/jit.dss.vstk.log
#rfc3161/rfc2630
TSAType=rfc3161
#dsCert/issuerDNAndSN/CertId
p1VerifyCertId=CertId
Compatible=true
dss.client.class=cn.com.jit.assp.client.DSSClientHttpUrlConnectionImpl
#dss.client.class=cn.com.jit.assp.client.DSSClientHttpClientImpl
#default/encAfterDec/secretEnvelop(use this mode after using VCTK do envelop) secretEnvelop:develop->RSAdecrypt->RSAencrypt->envelop
envelopType=default
#default unit KB and default size is 0,0 is not block;
packageSize=0
#default:10000 unit: ms
timeout=50000
connectTimeOut=50000
# default : system unicode
FileSystemCharSet=UTF-8
vstkVersion=20
EncryptMode=ecb
#package size every time, unit is byte
send_size=1048576
#bigger than this will take big transfer modle, unit is byte
bigdata_limit=20971520
first_read_timeout=10000
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.gtyingxin</groupId>
<artifactId>LegalPersonMonitor</artifactId>
<version>1.0-SNAPSHOT</version>
<properties>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
<spring.version>4.3.10.RELEASE</spring.version>
</properties>
<dependencies>
<!-- https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-databind -->
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<version>2.9.2</version>
</dependency>
<!--JsonString 转 bean-->
<dependency>
<groupId>net.sf.json-lib</groupId>
<artifactId>json-lib</artifactId>
<version>2.4</version>
<classifier>jdk15</classifier>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<version>4.5.3</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-core</artifactId>
<version>${spring.version}</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-context-support</artifactId>
<version>${spring.version}</version>
</dependency>
</dependencies>
</project>
\ No newline at end of file
package com.legalPersonMonitor.auth;
import com.legalPersonMonitor.config.AuthModeConfig;
import com.legalPersonMonitor.config.ParameterConfig;
import com.legalPersonMonitor.config.TaskConfig;
import com.legalPersonMonitor.data.*;
import com.legalPersonMonitor.utils.FormatBytesUtil;
import sun.misc.BASE64Decoder;
import java.io.IOException;
/**
* Created by gaoxiang on 2018/1/22.
*/
public class Authentication {
/**
* businessSerialNumberByte 流水号 byte[] 类型
* customerId 客户号 8字节 共用
* terminalId 终端号 2字节 共用 1.0写死 2.0用应用名称 FormatBytesUtil.hexStringToBytes(preAuthBean.getAppName());
* certificateNumber 证书标识 or 业务站点
* authApplyRetainData 客户端传入认证保留数据String
* authRetainTwoDataDesign 传入1.0 认证平台认证保留 2项数据 ( 已加密)
* authRetainFourDataDesign 传入1.0 认证平台认证保留 4项数据 ( 已加密)
* idcardAuthDataBase64DecodeAfter 传入1.0 认证平台认证ID验证数据( 已加密)
* pictureAuthDataBase64DecodeAfter 传入1.0 认证平台认证人像 ( 已加密)
* authCodeDataBase64DecodeAfter 传入1.0 认证平台认证认证码数据 ( 已加密)
* mode 认证模式
* authDate 根据模式组合成的数据
* version 协议版本 2字节 0x0001 共用
* commandType 命令类型 1字节 0x00(请求)0x01(应答) 共用
* command 命令 1字节 0x00(身份认证申请)0x01(身份认证) 修改值的内容为1
* commandContent 命令内容 1字节 保留 0x00 共用
* operation 操作 1字节 保留 0x00 共用
* auSPData 身份认证 二包 Socket数据报文
* authReturn 身份认证 1.0 平台二包 响应结果
* checkSignResult 验签是否正确
*/
private byte[] businessSerialNumberByte;
private byte[] customerId;
private byte[] terminalId;
private byte[] timeStamp;
private byte[] certificateNumber;
private byte[] authRetainTwoDataDesign=null;
private byte[] idcardAuthDataBase64DecodeAfter=null;
private byte[] pictureAuthDataBase64DecodeAfter=null;
private byte[] authCodeDataBase64DecodeAfter=null;
private byte[] authDataBase64Decode=null;
private byte[] authDate=null;
private byte[] version=new byte[]{0, 1};
private byte[] commandType = new byte[]{0};
private byte[] command = new byte[]{1};
private byte[] commandContent = new byte[]{0};
private byte[] operation = new byte[]{0};
private byte[] auSPData;
private byte[] customerId_Length=new byte[] { 1, 2, 3, 4, 5, 6, 7, 8 };
private byte[] timeStamp_Length=new byte[] { 1, 2,3,4};
public byte[] authExecute(AuthRequestBean authRequestBean){
customerId= FormatBytesUtil.getBytesFromString(customerId_Length,authRequestBean.getCustomerNumber());
terminalId= ParameterConfig.terminalId;
timeStamp= FormatBytesUtil.getBytesFromString(timeStamp_Length,authRequestBean.getTimeStamp());
businessSerialNumberByte=FormatBytesUtil.hexStringToBytes(authRequestBean.getBusinessSerialNumber());
certificateNumber=ParameterConfig.certificateNumber;
getauthRetainTwoDataDesign(authRequestBean.getAuthApplyRetainData());
idcardAuthDataBase64DecodeAfter=dataProcessingBase64Decode(TaskConfig.TASK_ID_DATA,authRequestBean.getIdcardAuthData());
authCodeDataBase64DecodeAfter=dataProcessingBase64Decode(TaskConfig.TASK_AUTHCODE_DATA,authRequestBean.getAuthCode());
pictureAuthDataBase64DecodeAfter=dataProcessingBase64Decode(TaskConfig.TASK_PIC_DATA,authRequestBean.getPhotoData());
AuthData au_0X4F = new AuthData(customerId, terminalId, timeStamp,businessSerialNumberByte, AuthModeConfig.IDENTITYMODEL_0X4F,
idcardAuthDataBase64DecodeAfter, authCodeDataBase64DecodeAfter, pictureAuthDataBase64DecodeAfter, authRetainTwoDataDesign, certificateNumber);
authDate = au_0X4F.getAuthenticationData();
SocketPackage auSP = new SocketPackage(version, commandType, command, commandContent, operation, authDate);
auSPData = auSP.getSocketPackage();
return auSPData;
}
public void getauthRetainTwoDataDesign(AuthApplyRetainBean retainDate){
String name=retainDate.getName();
String idNumber=retainDate.getIdNumber();
authRetainTwoDataDesign = new RetainData(name, idNumber, null, null).getReservasionBytes();
}
private byte[] excuteBase64Decode(String encodeData) throws IOException {
byte[] originalData= new BASE64Decoder().decodeBuffer(encodeData);
return originalData;
}
private byte[] dataProcessingBase64Decode(String dataName,String data ){
switch (dataName){
case TaskConfig.TASK_ID_DATA:
authDataBase64Decode=FormatBytesUtil.hexStringToBytes(data);
break;
case TaskConfig.TASK_AUTHCODE_DATA:
authDataBase64Decode=FormatBytesUtil.hexStringToBytes(data);
break;
case TaskConfig.TASK_PIC_DATA:
try {
authDataBase64Decode = excuteBase64Decode(data);
} catch (IOException e) {
e.printStackTrace();
}
break;
}
return authDataBase64Decode;
}
}
package com.legalPersonMonitor.config;
/**
* Created by gaoxiang on 2018/1/12.
*/
public class AuthModeConfig {
public static final byte[] IDENTITYMODEL_0X4F = new byte[] { 0x4f };
}
package com.legalPersonMonitor.config;
/**
* Created by gaoxiang on 2018/1/15.
*/
public class TaskConfig {
/**人像编码任务*/
public static final String TASK_PIC_DATA = "TASK_PIC_DATA";
/**ID编码任务*/
public static final String TASK_ID_DATA = "TASK_ID_DATA";
/**认证码编码任务*/
public static final String TASK_AUTHCODE_DATA = "TASK_AUTHCODE_DATA";
}
package com.legalPersonMonitor.connections;
import org.apache.http.*;
import org.apache.http.client.methods.CloseableHttpResponse;
import org.apache.http.client.methods.HttpPost;
import org.apache.http.entity.StringEntity;
import org.apache.http.impl.client.CloseableHttpClient;
import org.apache.http.impl.client.HttpClients;
import org.apache.http.util.EntityUtils;
import java.io.IOException;
/**
* Created by zhangdahui on 2017/5/18.
*/
public class HttpClientPool {
public static String postRequest(String url, String body) {
HttpPost httpPost = new HttpPost(url);
CloseableHttpClient hc = HttpClients.createDefault();
CloseableHttpResponse response = null;
StringEntity se = new StringEntity(body, "UTF-8");
se.setContentType("application/json");
httpPost.setEntity(se);
String respStr="";
try {
response = hc.execute(httpPost);
HttpEntity et = response.getEntity();
respStr = EntityUtils.toString(et);
return respStr;
} catch (IOException e) {
e.printStackTrace();
} finally {
}
return respStr;
}
}
package com.legalPersonMonitor.connections;
import com.fasterxml.jackson.core.JsonParseException;
import com.fasterxml.jackson.databind.JsonMappingException;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.legalPersonMonitor.data.AccessTokenRequset;
import com.legalPersonMonitor.data.AccessTokenResponse;
import com.legalPersonMonitor.data.WxResponseBean;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.net.URL;
import java.net.URLConnection;
import java.util.HashMap;
import java.util.Map;
public class SendRequset {
public static String sendGet(String url, String param) {
String result = "";
BufferedReader in = null;
try {
String urlNameString = url + "?" + param;
URL realUrl = new URL(urlNameString);
// 打开和URL之间的连接
URLConnection connection = realUrl.openConnection();
// 设置通用的请求属性
connection.setRequestProperty("accept", "*/*");
connection.setRequestProperty("connection", "Keep-Alive");
connection.setRequestProperty("user-agent",
"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1;SV1)");
// 建立实际的连接
connection.connect();
// 获取所有响应头字段
// Map<String, List<String>> map = connection.getHeaderFields();
// // 遍历所有的响应头字段
// for (String key : map.keySet()) {
// System.out.println(key + "--->" + map.get(key));
// }
// 定义 BufferedReader输入流来读取URL的响应
in = new BufferedReader(new InputStreamReader(
connection.getInputStream()));
String line;
while ((line = in.readLine()) != null) {
result += line;
}
} catch (Exception e) {
System.out.println("发送GET请求出现异常!" + e);
e.printStackTrace();
}
// 使用finally块来关闭输入流
finally {
try {
if (in != null) {
in.close();
}
} catch (Exception e2) {
e2.printStackTrace();
}
}
return result;
}
/**
* 向指定 URL 发送POST方法的请求
*
* @param url
* 发送请求的 URL
* @param param
* 请求参数,请求参数应该是 name1=value1&name2=value2 的形式。
* @return 所代表远程资源的响应结果
*/
public static String sendPost(String url, String param) {
PrintWriter out = null;
BufferedReader in = null;
String result = "";
try {
URL realUrl = new URL(url);
// 打开和URL之间的连接
URLConnection conn = realUrl.openConnection();
// 设置通用的请求属性
conn.setRequestProperty("accept", "*/*");
conn.setRequestProperty("connection", "Keep-Alive");
conn.setRequestProperty("user-agent",
"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1;SV1)");
// 发送POST请求必须设置如下两行
conn.setDoOutput(true);
conn.setDoInput(true);
// 获取URLConnection对象对应的输出流
out = new PrintWriter(conn.getOutputStream());
// 发送请求参数
out.print(param);
// flush输出流的缓冲
out.flush();
// 定义BufferedReader输入流来读取URL的响应
in = new BufferedReader(
new InputStreamReader(conn.getInputStream()));
String line;
while ((line = in.readLine()) != null) {
result += line;
}
} catch (Exception e) {
System.out.println("发送 POST 请求出现异常!"+e);
e.printStackTrace();
}
//使用finally块来关闭输出流、输入流
finally{
try{
if(out!=null){
out.close();
}
if(in!=null){
in.close();
}
}
catch(IOException ex){
ex.printStackTrace();
}
}
return result;
}
//获取凭证
public AccessTokenResponse getAccessToken(AccessTokenRequset accessTokenRequset){
try {
String s=sendGet(accessTokenRequset.getAccessTokenUrl(), "corpid="+accessTokenRequset.getCorpid()+"&corpsecret="+accessTokenRequset.getCorpsecret());
ObjectMapper mapper = new ObjectMapper();
AccessTokenResponse accessTokenResponse=mapper.readValue(s, AccessTokenResponse.class);
return accessTokenResponse;
} catch (Exception e) {
return null;
}
}
//发送信息
public WxResponseBean sendTextMessage(AccessTokenResponse accessTokenResponse, String sendjson){
ObjectMapper mapper = new ObjectMapper();
String result=sendPost("https://qyapi.weixin.qq.com/cgi-bin/message/send?access_token="+accessTokenResponse.getAccess_token(), sendjson);
WxResponseBean wxResultMassage=new WxResponseBean();
try {
wxResultMassage = mapper.readValue(result,WxResponseBean.class);
} catch (JsonParseException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (JsonMappingException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
return wxResultMassage;
}
}
package com.legalPersonMonitor.connections;
import com.legalPersonMonitor.config.ParameterConfig;
import java.io.IOException;
import java.net.DatagramPacket;
import java.net.DatagramSocket;
import java.net.SocketException;
/**
* @author gao
*/
public class SocketSender {
public static byte[] sendSocketPackage(byte[] socketPackage) {
DatagramPacket sendPacket = new DatagramPacket(socketPackage, socketPackage.length, ParameterConfig.ia, ParameterConfig.port);
DatagramPacket receivePacket = new DatagramPacket(new byte[300], 300);
try (DatagramSocket udpClient = new DatagramSocket()) {
udpClient.send(sendPacket);
udpClient.setSoTimeout(10000);
udpClient.receive(receivePacket);
return receivePacket.getData();
} catch (SocketException e) {
System.out.println("udpClient创建失败");
e.printStackTrace();
} catch (IOException e) {
System.out.println("send/receive调用失败");
e.printStackTrace();
}
return null;
}
}
package com.legalPersonMonitor.data;
/**
* Created by gaoxiang on 2017/12/29.
*/
public class AccessTokenRequset {
private String accessTokenUrl;
private String corpid;
private String corpsecret;
public String getAccessTokenUrl() {
return accessTokenUrl;
}
public void setAccessTokenUrl(String accessTokenUrl) {
this.accessTokenUrl = accessTokenUrl;
}
public String getCorpid() {
return corpid;
}
public void setCorpid(String corpid) {
this.corpid = corpid;
}
public String getCorpsecret() {
return corpsecret;
}
public void setCorpsecret(String corpsecret) {
this.corpsecret = corpsecret;
}
public AccessTokenRequset(String accessTokenUrl, String corpid, String corpsecret) {
super();
this.accessTokenUrl = accessTokenUrl;
this.corpid = corpid;
this.corpsecret = corpsecret;
}
public AccessTokenRequset() {
super();
}
@Override
public String toString() {
return "AccessTokenRequset [accessTokenUrl=" + accessTokenUrl + ", corpid=" + corpid + ", corpsecret="
+ corpsecret + "]";
}
}
package com.legalPersonMonitor.data;
/**
* Created by gaoxiang on 2017/12/29.
*/
public class AccessTokenResponse {
private int errcode;
private String errmsg;
private String access_token;
private int expires_in;
public int getErrcode() {
return errcode;
}
public void setErrcode(int errcode) {
this.errcode = errcode;
}
public String getErrmsg() {
return errmsg;
}
public void setErrmsg(String errmsg) {
this.errmsg = errmsg;
}
public String getAccess_token() {
return access_token;
}
public void setAccess_token(String access_token) {
this.access_token = access_token;
}
public int getExpires_in() {
return expires_in;
}
public void setExpires_in(int expires_in) {
this.expires_in = expires_in;
}
public AccessTokenResponse(String access_token, int expires_in) {
super();
this.access_token = access_token;
this.expires_in = expires_in;
}
public AccessTokenResponse() {
super();
}
@Override
public String toString() {
return "AccessTokenResponse [access_token=" + access_token + ", expires_in=" + expires_in + "]";
}
}
package com.legalPersonMonitor.data;
/**
* Created by gaoxiang on 2017/12/29.
*/
public class AuthApplyRetainBean {
private String name;
private String idNumber;
private String enableDate;
private String expireDate;
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getIdNumber() {
return idNumber;
}
public void setIdNumber(String idNumber) {
this.idNumber = idNumber;
}
public String getEnableDate() {
return enableDate;
}
public void setEnableDate(String enableDate) {
this.enableDate = enableDate;
}
public String getExpireDate() {
return expireDate;
}
public void setExpireDate(String expireDate) {
this.expireDate = expireDate;
}
}
package com.legalPersonMonitor.data;
import com.legalPersonMonitor.utils.FormatBytesUtil;
public class AuthData {
/**
* lengthOfTwo ID验证数据字段及认证吗数据字段总长 2字节
* lengthOfIdCheck ID验证数据长度 2字节
* lengthOfAuthCodeData 认证码数据长度 2字节
* lengthOfPicture 照片长度 4字节
* lengthOfReservasion 认证申请保留数据长度 2字节
*/
private byte[] lengthOfTwo;
private byte[] lengthOfIdCheck;
private byte[] lengthOfAuthCodeData;
private byte[] lengthOfPicture;
private byte[] lengthOfReservasion;
private byte[] customerId;
private byte[] terminalId;
private byte[] timestamp;
private byte[] streamNumber;
private byte[] identityModel;
private byte[] idCheckData;
private byte[] authCodeData;
private byte[] pictureData;
private byte[] reservationData;
private byte[] certificateNumber;
/**
*
* @param customerId 客户号 8字节
* @param terminalId 终端号 2字节
* @param timestamp 时间戳 4字节
* @param streamNumber 业务流水号 9字节
* @param identityModel 认证模式 1字节
* @param idCheckData ID验证数据 变长 可为空
* @param authCodeData 认证码数据 变长 可为空
* @param pictureData 照片数据 变长 可为空
* @param reservationData 认证申请保留数据 变长 可为空
* @param certificateNumber 证书序列号 32字节
*/
public AuthData(byte[] customerId, byte[] terminalId, byte[] timestamp, byte[] streamNumber, byte[] identityModel,
byte[] idCheckData, byte[] authCodeData, byte[] pictureData, byte[] reservationData, byte[] certificateNumber) {
super();
this.customerId = customerId;
this.terminalId = terminalId;
this.timestamp = timestamp;
this.streamNumber = streamNumber;
this.identityModel = identityModel;
int idCheckLengthTemp = 0;
int verificationLengthTemp = 0;
this.lengthOfIdCheck = new byte[] { 0, 0 };
if (idCheckData != null) {
idCheckLengthTemp = idCheckData.length;
this.lengthOfIdCheck = FormatBytesUtil.getByteOfShort((short) idCheckData.length);
}
this.idCheckData = idCheckData;
this.lengthOfAuthCodeData = new byte[] { 0, 0 };
if (authCodeData != null) {
verificationLengthTemp = authCodeData.length;
this.lengthOfAuthCodeData = FormatBytesUtil.getByteOfShort((short) authCodeData.length);
}
this.authCodeData = authCodeData;
this.lengthOfTwo = FormatBytesUtil.getByteOfShort((short) (idCheckLengthTemp + verificationLengthTemp + 4));
this.lengthOfPicture = new byte[] { 0, 0, 0, 0 };
if (pictureData != null) {
this.lengthOfPicture = FormatBytesUtil.getBytesOfInt(pictureData.length);
}
this.pictureData = pictureData;
this.lengthOfReservasion = new byte[] { 0, 0 };
if (reservationData != null) {
this.lengthOfReservasion = FormatBytesUtil.getByteOfShort((short) reservationData.length);
}
this.reservationData = reservationData;
this.certificateNumber = certificateNumber;
}
public byte[] getAuthenticationData() {
byte[] data = FormatBytesUtil.concatAll(customerId, terminalId, timestamp, streamNumber, identityModel,
lengthOfTwo, lengthOfIdCheck, idCheckData, lengthOfAuthCodeData, authCodeData, lengthOfPicture, pictureData,
lengthOfReservasion, reservationData, certificateNumber);
return data;
}
}
package com.legalPersonMonitor.data;
/**
* Created by gaoxiang on 2017/12/29.
*/
public class AuthRequestBean {
/**
* customNumber :
* AppName :
* timeStamp :
* businessSerialNumber :
* authMode :
* photoData :
* authCode :
* idcardAuthData :
* authApplyRetainData :
*/
private String customerNumber;
private String appName;
private String timeStamp;
private String businessSerialNumber;
private String authMode;
private String photoData;
private String authCode;
private String idcardAuthData;
private AuthApplyRetainBean authApplyRetainData=new AuthApplyRetainBean();
public AuthApplyRetainBean getAuthApplyRetainData() {
return authApplyRetainData;
}
public void setAuthApplyRetainData(AuthApplyRetainBean authApplyRetainData) {
this.authApplyRetainData = authApplyRetainData;
}
public String getCustomerNumber() {
return customerNumber;
}
public void setCustomerNumber(String customerNumber) {
this.customerNumber = customerNumber;
}
public String getAppName() {
return appName;
}
public void setAppName(String appName) {
this.appName = appName;
}
public String getTimeStamp() {
return timeStamp;
}
public void setTimeStamp(String timeStamp) {
this.timeStamp = timeStamp;
}
public String getBusinessSerialNumber() {
return businessSerialNumber;
}
public void setBusinessSerialNumber(String businessSerialNumber) {
this.businessSerialNumber = businessSerialNumber;
}
public String getAuthMode() {
return authMode;
}
public void setAuthMode(String authMode) {
this.authMode = authMode;
}
public String getPhotoData() {
return photoData;
}
public void setPhotoData(String photoData) {
this.photoData = photoData;
}
public String getAuthCode() {
return authCode;
}
public void setAuthCode(String authCode) {
this.authCode = authCode;
}
public String getIdcardAuthData() {
return idcardAuthData;
}
public void setIdcardAuthData(String idcardAuthData) {
this.idcardAuthData = idcardAuthData;
}
}
package com.legalPersonMonitor.data;
/**
* Created by gaoxiang on 2017/12/29.
*/
public class AuthResponseBean {
/**
* customerNumber : LegalPersonChapter001
* appName : fripolice001
* timeStamp : 20171224
* businessSerialNumber : 410DEFAAAAAAA
* authResult : 0000
* authResultRetainData :
* success : true
* errorDesc :
*/
private String customerNumber;
private String appName;
private String timeStamp;
private String businessSerialNumber;
private String authResult;
private String authResultRetainData;
private boolean success;
private String errorDesc;
public String getCustomerNumber() {
return customerNumber;
}
public void setCustomerNumber(String customerNumber) {
this.customerNumber = customerNumber;
}
public String getAppName() {
return appName;
}
public void setAppName(String appName) {
this.appName = appName;
}
public String getTimeStamp() {
return timeStamp;
}
public void setTimeStamp(String timeStamp) {
this.timeStamp = timeStamp;
}
public String getBusinessSerialNumber() {
return businessSerialNumber;
}
public void setBusinessSerialNumber(String businessSerialNumber) {
this.businessSerialNumber = businessSerialNumber;
}
public String getAuthResult() {
return authResult;
}
public void setAuthResult(String authResult) {
this.authResult = authResult;
}
public String getAuthResultRetainData() {
return authResultRetainData;
}
public void setAuthResultRetainData(String authResultRetainData) {
this.authResultRetainData = authResultRetainData;
}
public boolean getSuccess() {
return success;
}
public void setSuccess(boolean success) {
this.success = success;
}
public String getErrorDesc() {
return errorDesc;
}
public void setErrorDesc(String errorDesc) {
this.errorDesc = errorDesc;
}
}
package com.legalPersonMonitor.data;
/**
* Created by gaoxiang on 2018/1/3.
*/
public class PreAuthResponseBean {
/**
* customerNumber : 客户号
* appName : 应用名称
* timeStamp : 20171224
* businessSerialNumber : 业务流水号
* randomNumber : 随机数
* success : 是否成功
* errorDesc : 错误信息描述
*/
private String customerNumber = "";
private String appName = "";
private String timeStamp;
private String businessSerialNumber;
private String randomNumber;
private boolean success = false;
private String errorDesc = "";
public String getCustomerNumber() {
return customerNumber;
}
public void setCustomerNumber(String customerNumber) {
this.customerNumber = customerNumber;
}
public String getAppName() {
return appName;
}
public void setAppName(String appName) {
this.appName = appName;
}
public String getTimeStamp() {
return timeStamp;
}
public void setTimeStamp(String timeStamp) {
this.timeStamp = timeStamp;
}
public String getBusinessSerialNumber() {
return businessSerialNumber;
}
public void setBusinessSerialNumber(String businessSerialNumber) {
this.businessSerialNumber = businessSerialNumber;
}
public String getRandomNumber() {
return randomNumber;
}
public void setRandomNumber(String randomNumber) {
this.randomNumber = randomNumber;
}
public boolean getSuccess() {
return success;
}
public void setSuccess(boolean success) {
this.success = success;
}
public String getErrorDesc() {
return errorDesc;
}
public void setErrorDesc(String errorDesc) {
this.errorDesc = errorDesc;
}
}
package com.legalPersonMonitor.data;
import com.legalPersonMonitor.encryption.EncryptionI;
import com.legalPersonMonitor.encryption.impl.OldEncryptionImpl;
import com.legalPersonMonitor.utils.FormatBytesUtil;
import java.io.UnsupportedEncodingException;
public class RetainData {
// 姓名
private String name;
// 身份证号
private String idNumber;
// 有效期起
private String validFrom;
// 有效期止
private String validEnd;
/*
* 网站上传信息 JSON字符串 必填 String jsonStr =
* "{'vendorIp':'202.211.100.100','venderName':'rzfw','businessType':'test','dealDate':'20161202'}";
*/
private byte[] updataInfo_JSON = new byte[] { 123, 39, 118, 101, 110, 100, 111, 114, 73, 112, 39, 58, 39, 50, 48,
50, 46, 50, 49, 49, 46, 49, 48, 48, 46, 49, 48, 48, 39, 44, 39, 118, 101, 110, 100, 101, 114, 78, 97, 109,
101, 39, 58, 39, 121, 105, 110, 103, 120, 105, 110, 105, 110, 102, 111, 39, 44, 39, 98, 117, 115, 105, 110,
101, 115, 115, 84, 121, 112, 101, 39, 58, 39, 116, 101, 115, 116, 39, 44, 39, 100, 101, 97, 108, 68, 97,
116, 101, 39, 58, 39, 50, 48, 49, 54, 49, 50, 48, 50, 39, 125 };
String json="";
public RetainData(String name, String idNumber, String validFrom, String validEnd) {
super();
this.name = name;
this.idNumber = idNumber;
this.validFrom = validFrom;
this.validEnd = validEnd;
}
public byte[] getReservasionBytes() {
EncryptionI oldEncryptionImpl=new OldEncryptionImpl();
// 各项信息长度固定
byte[] nameByte = new byte[45];
byte[] idNumberByte = new byte[18];
byte[] validFromByte = new byte[8];
byte[] validEndByte = new byte[8];
try {
// 姓名以UTF-8格式转换为byte[]
nameByte = FormatBytesUtil.copyByteToAnother(nameByte, name.getBytes("UTF-8"));
} catch (UnsupportedEncodingException e) {
e.printStackTrace();
return null;
}
// 身份证号中含有字母"X"的,一律大写
idNumberByte = FormatBytesUtil.getBytesFromString(idNumberByte, idNumber);
if (validFrom != null) {
validFromByte = FormatBytesUtil.getBytesFromString(validFromByte, validFrom);
}
if (validEnd != null) {
validEndByte = FormatBytesUtil.getBytesFromString(validEndByte, validEnd);
}
byte[] bytes = FormatBytesUtil.concatAll(nameByte, idNumberByte, validFromByte, validEndByte, updataInfo_JSON);
byte[] reservasionBytes = oldEncryptionImpl.getEncryption(bytes);
return reservasionBytes;
}
}
package com.legalPersonMonitor.data;
import com.legalPersonMonitor.config.ParameterConfig;
import com.legalPersonMonitor.signature.SignatureI;
import com.legalPersonMonitor.signature.impl.OldSignatureImpl;
import com.legalPersonMonitor.utils.FormatBytesUtil;
public class SocketPackage {
private byte[] version;
private byte[] commandType;
private byte[] command;
private byte[] commandContent;
private byte[] operation;
// 数据区长度 4字节
private byte[] dataLength;
private byte[] data;
// 签名长度 1字节
private byte[] signatureLength;
// 签名 变长
private byte[] signature;
/**
*
* @param version 协议版本 2字节 0x0001
* @param commandType 命令类型 1字节 0x00(请求)0x01(应答)
* @param command 命令 1字节 0x00(身份认证申请)0x01(身份认证)
* @param commandContent 命令内容 1字节 保留 0x00
* @param operation 操作 1字节 保留 0x00
* @param data 数据区 变长
*/
public SocketPackage(byte[] version, byte[] commandType, byte[] command, byte[] commandContent, byte[] operation,
byte[] data) {
super();
this.version = version;
this.commandType = commandType;
this.command = command;
this.commandContent = commandContent;
this.operation = operation;
this.dataLength = FormatBytesUtil.getBytesOfInt(data.length);
this.data = data;
}
public byte[] getSocketPackage() {
SignatureI oldSignatureImpl=new OldSignatureImpl();
byte[] clearText = FormatBytesUtil.concatAll(version, commandType, command, commandContent, operation,
dataLength, data);
byte[] cipherText = oldSignatureImpl.signature(ParameterConfig.strDN, ParameterConfig.strDigestAlg,clearText);
this.signatureLength = new byte[] { (byte) cipherText.length };
this.signature = cipherText;
byte[] socketPackage = FormatBytesUtil.concatAll(clearText, signatureLength, signature);
return socketPackage;
}
}
package com.legalPersonMonitor.data;
/**
* 微信返回结果模型
*/
public class WxResponseBean {
private String errcode;
private String errmsg;
private String invaliduser;
public String getInvaliduser() {
return invaliduser;
}
public void setInvaliduser(String invaliduser) {
this.invaliduser = invaliduser;
}
public String getErrcode() {
return errcode;
}
public void setErrcode(String errcode) {
this.errcode = errcode;
}
public String getErrmsg() {
return errmsg;
}
public void setErrmsg(String errmsg) {
this.errmsg = errmsg;
}
@Override
public String toString() {
return "WxResponseBean [errcode=" + errcode + ", errmsg=" + errmsg + "]";
}
}
package com.legalPersonMonitor.decryption;
public interface DecryptionI {
}
package com.legalPersonMonitor.decryption.impl;
public class NewDecryptionImpl {
}
package com.legalPersonMonitor.decryption.impl;
import com.legalPersonMonitor.decryption.DecryptionI;
public class OldDecryptionImpl implements DecryptionI {
}
package com.legalPersonMonitor.encryption;
public interface EncryptionI {
/**
* 加密
* @param bytes
* @return
*/
public byte[] getEncryption(byte[] bytes);
}
package com.legalPersonMonitor.encryption.impl;
public class NewEncryptionImpl {
}
package com.legalPersonMonitor.encryption.impl;
import cn.com.jit.assp.dsign.DSign;
import com.legalPersonMonitor.encryption.EncryptionI;
public class OldEncryptionImpl implements EncryptionI {
@Override
/**
* 加密
*/
public byte[] getEncryption(byte[] bytes){
DSign dSign = new DSign();
String signReturn = null;
DSign.init("./config/cssconfig.properties");
String[] alias = { "rzfw01" };
signReturn = dSign.encryptEnvelop(alias, bytes);
return signReturn.getBytes();
}
}
package com.legalPersonMonitor.monitor;
import com.legalPersonMonitor.connections.SendRequset;
import com.legalPersonMonitor.data.AccessTokenRequset;
import com.legalPersonMonitor.data.AccessTokenResponse;
import com.legalPersonMonitor.data.WxResponseBean;
/**
* Created by gaoxiang on 2018/1/22.
*/
public class SendToWeixin {
public void test(){
System.out.println("!!!!!!!!!!!!!!!!!!!!!!!!!");
}
public void sendToWeixinMain(){
String msgServiceState= "0X4F模式下的服务状态监控"+ServiceStateMonitoring.serviceStateMonitoringServer()+" ";
String msgTrustedPlatformStatus= "0X4F模式下的可信平台状态监控"+new TrustedPlatformStatusMonitoring().trustedPlatformStatusMonitoringServer()+" ";
String msgSignatureServerStatus = "签名服务器状态监控"+new SignatureServerStatusMonitoring().signatureServerStatusMonitoringServer();
SendRequset sr=new SendRequset();
AccessTokenRequset atrequset=new AccessTokenRequset("https://qyapi.weixin.qq.com/cgi-bin/gettoken","wx4244612882ba3018","5dqLUQ9S3CjhFfKXsmgl4Q9PogJEG6qieoyr4AEw1UI" );
AccessTokenResponse asresponse=sr.getAccessToken(atrequset);
String sendjson="{ \"touser\": \"@all\", \"toparty\": \" \", \"totag\": \" \", \"msgtype\": \"mpnews\", \"agentid\": "+1000003+", "
+ "\"mpnews\": { \"articles\":[ "
+ "{ \"title\": \""+"身份认证监控系统"+"\", "
+ "\"thumb_media_id\": \""+"2_VLquGGm4PEhhG-vG5_9SEfdLvNrvNPbdLH6DrZqieHHH5LqXbfqvLWljvcgGvF4"+"\", "
+ "\"author\": \"\", "
+ "\"content_source_url\": \"\", "
+ "\"content\": \""+msgServiceState+msgTrustedPlatformStatus+msgSignatureServerStatus+"\", "
+ "\"digest\": \""+"\", "
+ "\"show_cover_pic\": \"1\" } ] }, "
+ "\"safe\":0}";
WxResponseBean wx=sr.sendTextMessage(asresponse, sendjson);
}
}
package com.legalPersonMonitor.monitor;
import com.legalPersonMonitor.config.ParameterConfig;
import com.legalPersonMonitor.connections.HttpClientPool;
import com.legalPersonMonitor.data.*;
import net.sf.json.JSONObject;
import java.util.HashMap;
import java.util.Map;
/**
* Created by gaoxiang on 2018/1/22.
* 服务状态监控
*/
public class ServiceStateMonitoring {
private static String msgDescription="";
private static PreAuthResponseBean preAuthResponseBean;
public static String serviceStateMonitoringServer(){
try {
String preAuthRespStr = HttpClientPool.postRequest("http://121.22.111.251:9002/legalPerson/v2.0/auth_app", ParameterConfig.PREAUTH_JSONSTR);
JSONObject preAuthApply = JSONObject.fromObject(preAuthRespStr);
preAuthResponseBean = (PreAuthResponseBean) JSONObject.toBean(preAuthApply, PreAuthResponseBean.class);
if (!preAuthResponseBean.getSuccess()) {
msgDescription = preAuthResponseBean.getErrorDesc();
}
JSONObject jsonObject = JSONObject.fromObject(ParameterConfig.AUTH_JSONSTR);
Map config = new HashMap();
config.put("authApplyRetainData", AuthApplyRetainBean.class);
AuthRequestBean authRequestBean= (AuthRequestBean) JSONObject.toBean(jsonObject, AuthRequestBean.class, config);
authRequestBean.setBusinessSerialNumber(preAuthResponseBean.getBusinessSerialNumber());
String authResStr=JSONObject.fromObject(authRequestBean).toString();
String authRespStr = HttpClientPool.postRequest("http://121.22.111.251:9002/legalPerson/v2.0/authen_req",authResStr);
JSONObject authApply = JSONObject.fromObject(authRespStr);
AuthResponseBean authResponseBean= (AuthResponseBean) JSONObject.toBean(authApply, AuthResponseBean.class);
if(!authResponseBean.getSuccess()){
msgDescription=authResponseBean.getErrorDesc();
}
msgDescription=authResponseBean.getAuthResult();
}catch (Exception e){
msgDescription="服务状态监控超时错误";
}
return msgDescription;
}
}
package com.legalPersonMonitor.monitor;
import com.legalPersonMonitor.config.ParameterConfig;
import com.legalPersonMonitor.connections.SocketSender;
import com.legalPersonMonitor.utils.FormatBytesUtil;
import com.legalPersonMonitor.verification.VerificationI;
import com.legalPersonMonitor.verification.impl.OldVerificationImpl;
import java.util.Arrays;
import static com.legalPersonMonitor.config.ParameterConfig.VERIFICANTION_BYTE;
/**
* Created by gaoxiang on 2018/1/22.
* 签名服务器状态监控
*/
public class SignatureServerStatusMonitoring {
private static String msgDescription = "";
VerificationI oldVerificationImpl= new OldVerificationImpl();
public String signatureServerStatusMonitoringServer() {
try {
boolean aa = oldVerificationImpl.signCheck(VERIFICANTION_BYTE);
if (aa) {
msgDescription = "签名服务器正常运行";
} else {
msgDescription = "签名服务器出错";
}
}catch (Exception e){
msgDescription="连接超时";
}
return msgDescription;
}
}
\ No newline at end of file
package com.legalPersonMonitor.monitor;
import com.legalPersonMonitor.auth.Authentication;
import com.legalPersonMonitor.config.ParameterConfig;
import com.legalPersonMonitor.connections.SocketSender;
import com.legalPersonMonitor.data.AuthApplyRetainBean;
import com.legalPersonMonitor.data.AuthRequestBean;
import com.legalPersonMonitor.data.AuthResponseBean;
import com.legalPersonMonitor.utils.FormatBytesUtil;
import net.sf.json.JSONObject;
import java.util.Arrays;
import java.util.HashMap;
import java.util.Map;
/**
* Created by gaoxiang on 2018/1/22.
* 可信平台状态监控
*/
public class TrustedPlatformStatusMonitoring {
private String msgDescription = "";
public String trustedPlatformStatusMonitoringServer() {
try {
byte[] preAuthSendSocketData = SocketSender.sendSocketPackage(ParameterConfig.PREAUTH_BYTE);
if (preAuthSendSocketData != null) {
byte[] businessSerialNumberByte = Arrays.copyOfRange(preAuthSendSocketData, 24, 33);
String businessSerialNumber = FormatBytesUtil.bytesToHexString(businessSerialNumberByte);
JSONObject jsonObject = JSONObject.fromObject(ParameterConfig.AUTH_JSONSTR);
Map config = new HashMap();
config.put("authApplyRetainData", AuthApplyRetainBean.class);
AuthRequestBean authRequestBean = (AuthRequestBean) JSONObject.toBean(jsonObject, AuthRequestBean.class, config);
authRequestBean.setBusinessSerialNumber(businessSerialNumber);
byte[] responseBean = new Authentication().authExecute(authRequestBean);
byte[] authSendSocketData = SocketSender.sendSocketPackage(responseBean);
if (authSendSocketData != null) {
msgDescription = new String(Arrays.copyOfRange(authSendSocketData, 33, 37));
}
}
}catch (Exception e){
msgDescription="连接超时";
}
return msgDescription;
}
}
package com.legalPersonMonitor.server;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.FileSystemXmlApplicationContext;
/**
* Created by gaoxiang on 2018/1/23.
*/
public class StartUpTask {
public static void main(String aa[]){
ApplicationContext context = new FileSystemXmlApplicationContext("classpath:applicationContext.xml");
}
}
package com.legalPersonMonitor.signature;
public interface SignatureI {
public byte[] signature(String dn, String strDigestAlg, byte[] data);
}
package com.legalPersonMonitor.signature.impl;
public class NewSignatureImpl {
}
package com.legalPersonMonitor.signature.impl;
import cn.com.jit.assp.css.client.util.Base64;
import cn.com.jit.assp.dsign.DSign;
import com.legalPersonMonitor.signature.SignatureI;
public class OldSignatureImpl implements SignatureI {
@Override
public byte[] signature(String dn,String strDigestAlg,byte[] data) {
DSign dSign = new DSign();
DSign.init("./config/cssconfig.properties");
String signResultString = dSign.p1Sign(dn,strDigestAlg, data);
byte[] signResultByte = Base64.decode(signResultString);
return signResultByte;
}
}
package com.legalPersonMonitor.utils;
public class FormatBytesUtil {
/**
* 将byte数组转换为short类型
* @param bytes
* @return short
*/
public static short getShortFromBytes(byte[] bytes) {
return (short) ((0xff & bytes[0]) | (0xff00 & (bytes[1] << 8)));
}
/**
* 将byte数组转换为int类型
* @param bytes
* @return
*/
public static int getIntFromBytes(byte[] bytes) {
return (0xff & bytes[0]) | (0xff00 & (bytes[1] << 8))
| (0xff0000 & (bytes[2] << 16))
| (0xff000000 & (bytes[3] << 24));
}
/**
* 将short类型的数据转为byte数组 short类型为两个字节将这个字节转为byte数组长度为二 eg:id和认证码长度的转换
*
* @param data
* @return
*/
public static byte[] getByteOfShort(short data) {
byte[] bytes = new byte[2]; // 创建一个byte数组,长度设置为2
bytes[0] = (byte) (data & 0xff);// 参数与0xff做与运算
bytes[1] = (byte) ((data & 0xff00) >> 8);// 做过‘与’运算之后右移8位
return bytes;
}
/**
* int类型转换为4字节长度的byte数组 eg:时间戳的生成 数据区长度的转换
*
* @param data
* @return
*/
public static byte[] getBytesOfInt(int data) {
byte[] bytes = new byte[4];
bytes[0] = (byte) (data & 0xff);
bytes[1] = (byte) ((data & 0xff00) >> 8);
bytes[2] = (byte) ((data & 0xff0000) >> 16);
bytes[3] = (byte) ((data & 0xff000000) >> 24);
return bytes;
}
/**
* 时间戳
*
* @return 4字节时间戳
*/
// public static byte[] getTimestamp() {
// int i = (int) (System.currentTimeMillis() / 1000);
// byte[] time = getBytesOfInt(i);
// return time;
// }
public static String getTimestamp() {
long i = (System.currentTimeMillis());
String time = String.valueOf(i);
return time;
}
/**
* 把from中的内容拷贝到to中 eg:姓名拷贝到保留数据明文
*
* @param to
* @param from
* @return
*/
public static byte[] copyByteToAnother(byte[] to, byte[] from) {
for (int i = 0; i < from.length; i++) {
to[i] = from[i];
}
return to;
}
/**
* String类型转为byte数组,单字节转换方式
*
* @param bytes
* @param string
* @return
*/
public static byte[] getBytesFromString(byte[] bytes, String string) {
int j=string.length();
if(bytes.length<string.length()){
j=bytes.length;
}
for (int i = 0; i < j; i++) {
bytes[i] = (byte) string.charAt(i);
}
return bytes;
}
/**
* 将两个byte数组合并为一个
*
* @param byte1
* @param byte2
* @return byte_3
*/
public static byte[] byteMerger(byte[] byte1, byte[] byte2) {
byte[] byte3 = new byte[byte1.length + byte2.length];
System.arraycopy(byte1, 0, byte3, 0, byte1.length);
System.arraycopy(byte2, 0, byte3, byte1.length, byte2.length);
return byte3;
}
/**
* 用可变参数将所有的byte数组合并为一个
*
* @param first
* @param rest
* @return
*/
public static byte[] concatAll(byte[] first, byte[]... rest) {
int totalLength = first.length;
for (int i = 0; i < rest.length; i++) {
if (rest[i] != null) {
totalLength += rest[i].length;
}
}
byte[] result = new byte[totalLength];
System.arraycopy(first, 0, result, 0, first.length);
int offset = first.length;
for (int i = 0; i < rest.length; i++) {
if (rest[i] != null) {
System.arraycopy(rest[i], 0, result, offset, rest[i].length);
offset += rest[i].length;
}
}
return result;
}
/**
* 将byte数组转换成十六进制字符串 eg:流水号转换
*
* @author xia79
* @param ba
* @return
*/
public static String bytesToHexString(byte[] ba) {
String s = "";
for (int i = 0; i < ba.length; i++) {
s += String.format("%02X", ba[i]);
}
return s;
}
/**
* 将十六进制字符串转换成byte数组 eg:流水号转换
*
* @param hexString
* @return
*/
public static byte[] hexStringToBytes(String hexString) {
if (hexString == null || hexString.equals("")) {
return null;
}
hexString = hexString.toUpperCase();
int length = hexString.length() / 2;
char[] hexChars = hexString.toCharArray();
byte[] d = new byte[length];
for (int i = 0; i < length; i++) {
int pos = i * 2;
d[i] = (byte) (charToByte(hexChars[pos]) << 4 | charToByte(hexChars[pos + 1]));
}
return d;
}
private static byte charToByte(char c) {
return (byte) "0123456789ABCDEF".indexOf(c);
}
}
package com.legalPersonMonitor.verification;
public interface VerificationI {
public boolean signCheck(byte[] dataPackage);
}
package com.legalPersonMonitor.verification.impl;
public class NewVerificationImpl {
}
package com.legalPersonMonitor.verification.impl;
import cn.com.jit.assp.css.client.util.Base64;
import cn.com.jit.assp.dsign.DSign;
import com.legalPersonMonitor.verification.VerificationI;
import java.util.Arrays;
public class OldVerificationImpl implements VerificationI {
@Override
public boolean signCheck(byte[] dataPackage) {
byte[] dataLengthByte = Arrays.copyOfRange(dataPackage, 6, 10);
// 数据区长度
int dataLength =getIntFromBytes(dataLengthByte);
// 被签名数据
byte[] data = Arrays.copyOfRange(dataPackage, 0, 10 + dataLength);
// 签名长度数据
byte[] signatureLengthByte = Arrays.copyOfRange(dataPackage, 10 + dataLength, 11 + dataLength);
// 签名长度
int signatureLength = signatureLengthByte[0];
// 签名数据
byte[] signatureByte = Arrays.copyOfRange(dataPackage, 11 + dataLength, 11 + dataLength + signatureLength);
// 证书
byte[] zhengshu = Arrays.copyOfRange(data, data.length - 32, data.length);
DSign ds = new DSign();
DSign.init("./config/cssconfig.properties");
String certID = new String(zhengshu).trim();
String strDigetsAlg = "sm3";
long a = ds.p1Verify(certID, strDigetsAlg, Base64.encode(signatureByte), data);
if (a == 0) {
return true;
}
return false;
}
public static int getIntFromBytes(byte[] bytes) {
return (0xff & bytes[0]) | (0xff00 & (bytes[1] << 8))
| (0xff0000 & (bytes[2] << 16))
| (0xff000000 & (bytes[3] << 24));
}
}
package com.test;
import com.legalPersonMonitor.auth.Authentication;
import com.legalPersonMonitor.config.ParameterConfig;
import com.legalPersonMonitor.connections.HttpClientPool;
import com.legalPersonMonitor.connections.SocketSender;
import com.legalPersonMonitor.data.AuthApplyRetainBean;
import com.legalPersonMonitor.data.AuthRequestBean;
import com.legalPersonMonitor.data.AuthResponseBean;
import com.legalPersonMonitor.utils.FormatBytesUtil;
import net.sf.json.JSONObject;
import java.util.Arrays;
import java.util.HashMap;
import java.util.Map;
/**
* Created by gaoxiang on 2018/1/22.
*/
public class test {
public static void main(String args[]){
}
}
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:task="http://www.springframework.org/schema/task"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/task
http://www.springframework.org/schema/task/spring-task.xsd">
<bean id="checkXMLInput" class="com.legalPersonMonitor.monitor.SendToWeixin" />
<task:scheduled-tasks>
<task:scheduled ref="checkXMLInput" method="sendToWeixinMain" initial-delay="2000" fixed-delay="5000"/>
<!--<task:scheduled ref="checkXMLInput" method="sendToWeixinMain" cron="0 30 13 ? * *"/>-->
<!--<task:scheduled ref="checkXMLInput" method="sendToWeixinMain" cron="0 35 13 ? * *"/>-->
</task:scheduled-tasks>
</beans>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment