No announcement yet.

HTTP.Download problem.

  • Filter
  • Time
  • Show
Clear All
new posts

  • HTTP.Download problem.

    I'm not sure if there's a definitive answer to this but anyway. I wanted to upload a screenshot from my security camera to my webspace automatically at set intervals but couldn't find anything to do it with so I thought I'd make my own. It's almost working but I've got one problem that I can't solve. To be honest I don't think it's anything to do with AMS but any insight would be welcome.

    The camera should respond to "http://USERNAME:[email protected]/cgi-bin/snapshot.cgi" with a snapshot which I can save to my desktop with a constant filename and then ftp to my webspace. Everything works except that USERNAME:PASSWORD are not accepted and I get a user/password challenge.

    The URL fails in Firefox, IE, Edge but in Chrome it works without problem and displays the snapshot.

    Does HTTP.Download differ from a normal request for a web page? I've got no idea how it works, any ideas?

  • #2
    I've got one step further by editing my windows credentials (added a new entry in Windows Credentials using device network name rather than IP together with user and password). The challenge still pops up but it is fully populated so I just need to work out how to OK it automatically.
    Last edited by longedge; 07-29-2017, 02:19 AM.


    • #3
      If you want to pass the username and password in the URL, I believe you need to use HTTP.Submit() with SUBMITWEB_GET. I could be wrong - I have used this years ago... Also, if this is basic authentication, couldn't you use the AuthData table?



      • #4
        Thanks for the reply Ulrich. I have got to the point where I just have to click OK but this defeats the object of leaving the app to it's own devices. I'll look at those actions. It's just something interesting to do to fill some spare time to be honest so not a 'biggy'.