Web Connection
Hot Swap EXE and Authentication
Gravatar is a globally recognized avatar based on your email address. Hot Swap EXE and Authentication
  Paul Nesci
  All
  Feb 6, 2021 @ 08:12am

Hi Rick en All I'm confused about using ADMIN.aspx or ../wc.wc?wwmaint~FileUpload to upgrade my Restful API. The new EXE is on my Local Machine (same local DIR structure) and trying to send it to the Service. web.config and wc.ini edited and checked, permissions checked.

I unsure how to get Authentication up by calling ADMIN remotely (pass credentials?) to try it manually. When I push the file using ~FileUpload I just get the file with 0 bytes.

Thanks Paul

Gravatar is a globally recognized avatar based on your email address. re: Hot Swap EXE and Authentication
  Rick Strahl
  Paul Nesci
  Feb 6, 2021 @ 02:59pm

You should get an authentication dialog which logs you in and verifies who you are. Permissions for the copy process are determined by the Host Web application, which is set in the Application Pool's Impersonation configuration. Make sure that account used has rights to write a file in the location of the UpdateExe setting in web.config (or wc.ini if using ISAPI).

Hotswapping only works reliably in COM, but the upload should work and produce a file.

+++ Rick ---

Gravatar is a globally recognized avatar based on your email address. re: Hot Swap EXE and Authentication
  Paul Nesci
  Rick Strahl
  Feb 6, 2021 @ 05:14pm

Hi Rick - when you say "has rights to write a file in the location of the UpdateExe" you mean "location" as the destination? The new EXE is on my Local machine and the destination is an Amazon Lightsail server.

I am not regularly getting a Authentication dialogue? I cleared browsing history and got 1 but cannot seem to get another with this process or trying to load ADMIN. Is there other Browser stuff I need to clear?

Actually the location of the Update EXE was confusion - like I thought it would know where to write the file so programmatically I thought ../wc.wc?wwmaint~FileUpload should be told where to find the source?

Gravatar is a globally recognized avatar based on your email address. re: Hot Swap EXE and Authentication
  Paul Nesci
  Rick Strahl
  Feb 6, 2021 @ 05:45pm

UPDATE: I used an version of IE that had not been to the site and bingo got a AUTH Login? Must have something to do with Cookies not being cleared.

Importantly, I could use the ADMIN page to upload an EXE - which gave me a Get File dialogue so I could pick my "local" new EXE 😃 It uploaded no issue and hot swapped.

Rick the error must be finding the source upload file and this is my confusion with the setting in Web.Conf and WC.INI. I obviously have permissions correct as using Administrator.

Just tested programmatically ../wc.wc?wwmaint~FileUpload fom the same IE and it failed.

[EDIT] More on this... I just walked through DEBUG for this part called when using URl: lcFileBuffer is returning an empty value and lcFileName is correct. It seems the whole Multipart thing is looking through the URLString for some sort of value? (Content-Type & boundary). I put this down for now as it has to be a code error or something I needed to do at install.

Thanks for any assitance.

© 1996-2024