Passing Passwords ARGS
-
I have a login web page writtin in C#.Net, when the user logs to goes against AD, if that is successful, then it passes the user name and password to an exe that is also written in C#.Net that checks if the user name is sync with our other network applications. The problem I am having is that user can not have any spaces in there password, if they do it will get chopped of any not sync the correct password to the apps, any ideas on how I can fix this problem? Thanks har04mich
-
I have a login web page writtin in C#.Net, when the user logs to goes against AD, if that is successful, then it passes the user name and password to an exe that is also written in C#.Net that checks if the user name is sync with our other network applications. The problem I am having is that user can not have any spaces in there password, if they do it will get chopped of any not sync the correct password to the apps, any ideas on how I can fix this problem? Thanks har04mich
Have a look at the parameters that you are passing. You might try putting quotes around them: " This will not parse as part of the parameters; but be sure to escape any existing "s appropriately. By the way, its extremely bad practice passing passwords as command-line parameters: I'd suggest trying to have the password checked by your web app against the domain, and then just passing the user's name itself to your separate application to do whatever it does with it.