title: Curl or Lynx scripting with Chrome Cookie
body: <p>Just looking for someone to point me in the right direction. I need to script an interaction with a site that uses a "trust this device" cookie, and uses a log in portal. I found the cookie in Chrome, but not sure what to do next. This will be hosted on a CentOS 7 system.</p>
  
  <p>After authenticating to the login portal, I need to access another page using the "trust this device" cookie and the session cookie so I can download files. Manually downloading files everyday gets tedious, and the owner of the site does not want to use SFTP.</p>
  
  <p>Update 1 : 
  There was some confusion in my request (I could have made it more clear), I am NOT looking for someone to "write code" for me. This is more a sanity check as I learn how this process works. Please simply point me in the right direction as far as tools and general procedure.</p>
  
  <p>Update 2 :
  Using the "Copy as curl" option found in most web browsers, I was able to get the correct header information needed for authenticating.</p>
  
  <p>Instead of</p>
  
  <pre><code>curl -b "xxx=xxx"
  </code></pre>
  
  <p>I needed</p>
  
  <pre><code>curl  -H "Cookie: XXXX="%"2Fwpsnew; xxx=xxx"
  </code></pre>
  
  <p>When adding the -c switch, I can now save the session cookie. Further testing is needed, but at least there is progress.</p>
  
  <p>EDIT</p>
  
  <p>Using the Chrome feature for copying curl commands from the history (this is found in Firefox as well), I was able to partially reproduce results. However in my case I was not able to log in as the site I was working with uses additional js that modifies the cookies.</p>
  
  <p>This initial question can be closed, I will open a new post for more specific parts of my project.</p>