title: Spring Boot 2 -- security taglibs not found, wrong taglib version in the java jsp
body: <p>I know there are a ton of similar questions like this,  but I can't seem to find the answer for Spring Boot 2.  I am getting this error:</p>
  
  <pre><code>Caused by: org.apache.jasper.JasperException: The absolute uri: [http://www.springframework.org/security/tags] 
  cannot be resolved in either web.xml or the jar files deployed with this application
  </code></pre>
  
  <p>So I looked into the /work directory and found the java of the jsp,  and found this line:</p>
  
  <pre><code>_jspx_dependants.put("/WEB-INF/lib/spring-security-taglibs-3.2.0.RELEASE.jar", Long.valueOf(1524843694000L));
  </code></pre>
  
  <p>Now my pom has it at spring-security-taglibs-5.0.6.RELEASE.jar and that is in the /lib directory.</p>
  
  <p>I am also using apache tiles 3.0.5.  Don't know if that maters at all.  </p>
  
  <p>Here are my pom entries:</p>
  
  <pre><code>&lt;dependency&gt;
      &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
      &lt;artifactId&gt;spring-boot-starter-web&lt;/artifactId&gt;        
  &lt;/dependency&gt;
  
  &lt;dependency&gt;
      &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
      &lt;artifactId&gt;spring-boot-starter-data-jpa&lt;/artifactId&gt;
      &lt;exclusions&gt;
          &lt;exclusion&gt;
              &lt;groupId&gt;org.apache.tomcat&lt;/groupId&gt;
              &lt;artifactId&gt;tomcat-jdbc&lt;/artifactId&gt;
          &lt;/exclusion&gt;
      &lt;/exclusions&gt;       
  &lt;/dependency&gt;
  
  &lt;dependency&gt;
      &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
      &lt;artifactId&gt;spring-boot-starter-security&lt;/artifactId&gt;
  &lt;/dependency&gt;
  
  &lt;dependency&gt;
      &lt;groupId&gt;org.springframework.security&lt;/groupId&gt;
      &lt;artifactId&gt;spring-security-taglibs&lt;/artifactId&gt;
  &lt;/dependency&gt;   
  
  &lt;dependency&gt;
      &lt;groupId&gt;org.springframework&lt;/groupId&gt;
      &lt;artifactId&gt;spring-messaging&lt;/artifactId&gt;
  &lt;/dependency&gt;   
  
  &lt;dependency&gt;
      &lt;groupId&gt;org.springframework&lt;/groupId&gt;
      &lt;artifactId&gt;spring-websocket&lt;/artifactId&gt;
  &lt;/dependency&gt;
  &lt;dependency&gt;
      &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
      &lt;artifactId&gt;spring-boot-starter-tomcat&lt;/artifactId&gt;
      &lt;scope&gt;provided&lt;/scope&gt;
  &lt;/dependency&gt;
  &lt;dependency&gt;
      &lt;groupId&gt;org.apache.tomcat.embed&lt;/groupId&gt;
      &lt;artifactId&gt;tomcat-embed-jasper&lt;/artifactId&gt;
      &lt;scope&gt;provided&lt;/scope&gt;
  &lt;/dependency&gt;
  
      &lt;dependency&gt;
          &lt;groupId&gt;javax.servlet&lt;/groupId&gt;
          &lt;artifactId&gt;javax.servlet-api&lt;/artifactId&gt;
          &lt;scope&gt;provided&lt;/scope&gt;
      &lt;/dependency&gt;
      &lt;!-- https://mvnrepository.com/artifact/javax.servlet.jsp/jsp-api --&gt;
      &lt;dependency&gt;
          &lt;groupId&gt;javax.servlet.jsp&lt;/groupId&gt;
          &lt;artifactId&gt;jsp-api&lt;/artifactId&gt;
          &lt;version&gt;2.2&lt;/version&gt;
          &lt;scope&gt;provided&lt;/scope&gt;
      &lt;/dependency&gt;
      &lt;dependency&gt;
          &lt;groupId&gt;javax.servlet&lt;/groupId&gt;
          &lt;artifactId&gt;jstl&lt;/artifactId&gt;
      &lt;/dependency&gt;
  
  &lt;!--  Tiles --&gt;
  &lt;dependency&gt;
      &lt;groupId&gt;org.apache.tiles&lt;/groupId&gt;
      &lt;artifactId&gt;tiles-jsp&lt;/artifactId&gt;
      &lt;version&gt;${apache.tiles.version}&lt;/version&gt;
  &lt;/dependency&gt;
  
  &lt;dependency&gt;
      &lt;groupId&gt;org.apache.tiles&lt;/groupId&gt;
      &lt;artifactId&gt;tiles-core&lt;/artifactId&gt;
      &lt;version&gt;${apache.tiles.version}&lt;/version&gt;
      &lt;scope&gt;compile&lt;/scope&gt;
  &lt;/dependency&gt;
  
  &lt;dependency&gt;
      &lt;groupId&gt;org.apache.tiles&lt;/groupId&gt;
      &lt;artifactId&gt;tiles-api&lt;/artifactId&gt;
      &lt;version&gt;${apache.tiles.version}&lt;/version&gt;
      &lt;scope&gt;compile&lt;/scope&gt;
  &lt;/dependency&gt;
  
  &lt;dependency&gt;
      &lt;groupId&gt;org.apache.tiles&lt;/groupId&gt;
      &lt;artifactId&gt;tiles-servlet&lt;/artifactId&gt;
      &lt;version&gt;${apache.tiles.version}&lt;/version&gt;
  &lt;/dependency&gt;
  
  &lt;dependency&gt;
      &lt;groupId&gt;org.apache.tiles&lt;/groupId&gt;
      &lt;artifactId&gt;tiles-template&lt;/artifactId&gt;
      &lt;version&gt;${apache.tiles.version}&lt;/version&gt;
  &lt;/dependency&gt;
  </code></pre>
  
  <p>Any ideas how that version gets into the java of the jsp?</p>
  
  <p><strong>UPDATE</strong>
  I no longer think it's a Spring Boot 2 problem.  I reverted to boot 1.5.15 and I got the same error.  I even reverted further back to a simple spring project (4.3.18.RELEASE and spring-security 4.2.7.RELEASE)  and I get the same error.  If, however, I revert all the way back to spring security 3.2.0,  it works. </p>
  
  <p>I must have a dependency conflict somewhere, or the old security version is including a dependency that 4.x is not.</p>
  
  <p>I have also discovered that the regular spring tags cannot be found either.  IE:</p>
  
  <pre><code>&lt;%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%&gt;
  &lt;%@ taglib prefix="spring" uri="http://www.springframework.org/tags" %&gt;
  &lt;%@ taglib prefix="sec" uri="http://www.springframework.org/security/tags"%&gt; 
  </code></pre>
  
  <p>is throwing an error about not finding <a href="http://www.springframework.org/tags" rel="nofollow noreferrer">http://www.springframework.org/tags</a> and if I switch the order of "spring" and "sec" I get the error for which ever tag lib is first.  BUT -- I do not get an error for <a href="http://java.sun.com/jsp/jstl/core" rel="nofollow noreferrer">http://java.sun.com/jsp/jstl/core</a>  so it's not a general "loading taglib" error.</p>