{"id":421,"date":"2018-02-04T04:42:36","date_gmt":"2018-02-04T04:42:36","guid":{"rendered":"http:\/\/emacslisp.com\/?p=421"},"modified":"2018-02-04T04:44:05","modified_gmt":"2018-02-04T04:44:05","slug":"spring-tomcat-integration-error","status":"publish","type":"post","link":"http:\/\/emacslisp.com\/?p=421","title":{"rendered":"Spring Tomcat &#8211; integration error"},"content":{"rendered":"<p>Spring with Tomcat<\/p>\n<p>add spring security, then restart tomcat get the following error.<\/p>\n<pre lang=\"java\" line=\"1\">\r\nCaused by: java.util.zip.ZipException: invalid LOC header (bad signature)\r\n\tat java.util.zip.ZipFile.read(Native Method)\r\n\tat java.util.zip.ZipFile.access$1400(ZipFile.java:60)\r\n\tat java.util.zip.ZipFile$ZipFileInputStream.read(ZipFile.java:717)\r\n\tat java.util.zip.ZipFile$ZipFileInflaterInputStream.fill(ZipFile.java:419)\r\n\tat java.util.zip.InflaterInputStream.read(InflaterInputStream.java:158)\r\n\tat sun.misc.IOUtils.readFully(IOUtils.java:65)\r\n\tat java.util.jar.JarFile.getBytes(JarFile.java:425)\r\n\tat java.util.jar.JarFile.getManifestFromReference(JarFile.java:193)\r\n\tat java.util.jar.JarFile.getManifest(JarFile.java:180)\r\n\tat org.apache.catalina.webresources.AbstractSingleArchiveResourceSet.initInternal(AbstractSingleArchiveResourceSet.java:140)\r\n\t... 13 more\r\n <\/pre>\n<p>try to build on console.<\/p>\n<p>$ mvn package.<\/p>\n<p>if mvn says some jar\/war is interuptted,<br \/>\nthen delete these files and let mvn to download them again<\/p>\n<p>Spring 5 has to default a passwordEncoder<\/p>\n<p>However, if passwordEncoder is set to be NoOpPasswordEncoder to &#8216;ignore&#8217; passwordEncorder<\/p>\n<pre lang=\"xml\" line=\"1\" escaped=\"true\">\r\n<bean id=\"passwordEncoder\"\r\nclass=\"org.springframework.security.crypto.password.NoOpPasswordEncoder\"\r\nfactory-method=\"getInstance\">\r\n\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Spring with Tomcat add spring security, then restart tomcat get the following error. Caused by: java.util.zip.ZipException: invalid LOC header (bad signature) at java.util.zip.ZipFile.read(Native Method) at java.util.zip.ZipFile.access$1400(ZipFile.java:60) at java.util.zip.ZipFile$ZipFileInputStream.read(ZipFile.java:717) at java.util.zip.ZipFile$ZipFileInflaterInputStream.fill(ZipFile.java:419) at java.util.zip.InflaterInputStream.read(InflaterInputStream.java:158) at sun.misc.IOUtils.readFully(IOUtils.java:65) at java.util.jar.JarFile.getBytes(JarFile.java:425) at java.util.jar.JarFile.getManifestFromReference(JarFile.java:193) at java.util.jar.JarFile.getManifest(JarFile.java:180) at org.apache.catalina.webresources.AbstractSingleArchiveResourceSet.initInternal(AbstractSingleArchiveResourceSet.java:140) &#8230; 13 more try to build on console. $ mvn package. if mvn [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[14],"tags":[],"class_list":["post-421","post","type-post","status-publish","format-standard","hentry","category-java"],"_links":{"self":[{"href":"http:\/\/emacslisp.com\/index.php?rest_route=\/wp\/v2\/posts\/421","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/emacslisp.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/emacslisp.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/emacslisp.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/emacslisp.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=421"}],"version-history":[{"count":2,"href":"http:\/\/emacslisp.com\/index.php?rest_route=\/wp\/v2\/posts\/421\/revisions"}],"predecessor-version":[{"id":423,"href":"http:\/\/emacslisp.com\/index.php?rest_route=\/wp\/v2\/posts\/421\/revisions\/423"}],"wp:attachment":[{"href":"http:\/\/emacslisp.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=421"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/emacslisp.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=421"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/emacslisp.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=421"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}