Utilize Ignition user management with WebDev module

Hi,

I have built a pretty basic Web page that interfaces with my main Ignition gateway. I do this using the WebDev module, and utilizing the system.tag.read and write functions within python code to send JSON data to and from with Ajax POST methods.

My customer would now like to be able to log into this web page using Ignition credentials so we can track user actions.
How could this be implemented? I’m sure i can get them to enter their username, and check that against Ignition whether its a valid user or not, but how can i deal with passwords? I suppose i can use “system.security.validateUser”, but that means sending the password over the Ajax POST method in plain text?

I know this would be a great application to utilize the new Perspective module, but that might not be an option for some time.

Yes, unless you set up HTTPS for your gateway…

Going to have to read up on the Gateway Network settings i think…

I presume if you enable SSL on the gateway then it will only affect external requests such as through WebDev, and no client-gateway comms?

No, it’s all HTTP comms, including client/designer. Why would you want otherwise?

You can force HTTPS on specific WebDev endpoints…

Also, why not just use the built in authentication into your WebDev page? Then all user info is in the session data and can be logged.

I don’t think i really want to enable ETTPS for endpoints, as that opens a whole new can of worms with enabling SSL on gateway. I shouldn’t really need it if i’m just communicating locally with a device on the same local network as my gateway.

Enabling authentication might do the trick. Doesn’t seem to be an explanation of what format to send the user credentials in though.
I’m not a power user in HTML applications by any means, just struggling through to create a very basic application for local use only.

https://docs.inductiveautomation.com/display/DOC79/Web+Dev

It is simple HTTP basic authentication when enabled. Your browser should prompt for user/pass after enabling.