title: Can't struts2 detect the content of a file? (Renaming extension trouble)
body: <p>We have an application done with struts2. We limited the uploaded files to microsoft documents and acrobat pdf. All go fine. But when a user change the extension of the file, struts 2 is unable to detect that change and accept the file. </p>
  
  <p>For example logo.png -> logo.pdf</p>
  
  <p>Our configuration in the struts2 file is like this:</p>
  
  <pre><code>&lt;interceptor-ref name="interceptorFileStack"&gt;
              &lt;param name="fileUpload.allowedTypes"&gt;application/pdf,application/msword,application/vnd.openxmlformats-officedocument.wordprocessingml.document&lt;/param&gt;
              &lt;param name="fileUpload.allowedExtensions"&gt;.pdf,.docx,.doc&lt;/param&gt;
              &lt;param name="fileUpload.maximumSize"&gt;4194304&lt;/param&gt;
  &lt;/interceptor-ref&gt;
  </code></pre>
  
  <p>I thought that allowedExtensions control the extension, and allowedTypes the content of the file...</p>
  
  <p>Anyway to detect that change of the extension only with struts 2? Or i need another library? Any recommendation?</p>