title: Check uploading file is password protected or not in Javascript or jQuery
body: <p>Please help me on this.</p>
  
  <p>I have some file upload functionality in my application which is implemented using Javascript/jQuery on the front-end and an AJAX call to send the file object to the back-end written in Java.</p>
  
  <p>I need to detect if the file uploaded is password protected. If it is then I want to throw an error to the user.</p>
  
  <p>Is there an option to check this on the front-end using Javascript/jQuery or should I do it in the back end?</p>
  
  <p>In my Java middle-ware I am using the SmartUpload class to fetch the file object and insert it into a DB (blob format).</p>
  
  <p>Please suggest which is better and why.</p>
  
  <p>Thanks in advance. </p>