Hi Folks,
Good Evening,
I want to get username of currently logged windows user. is it
possible??
If Possible… please attach the sample code for more reference.
Please advise.
Thanks&Regards,
Ashokkumar
Hi Folks,
Good Evening,
I want to get username of currently logged windows user. is it
possible??
If Possible… please attach the sample code for more reference.
Please advise.
Thanks&Regards,
Ashokkumar
System properties.
–rob
Sent from my cell…excuse typos
On Monday, 30 September 2013 05:14:32 UTC-5, ihorse rails wrote:
Hi Folks,
Good Evening,
I want to get username of currently logged windows user. is it possible??
Currently logged in where, exactly? It’s certainly not going to be
available from a web browser session under most circumstances. There’s
NTLM
authentication which can do this, but it only works if the user has
marked
the site requesting it as “trusted”.
Some Googling for “ntlm authentication rails” turned up a couple gems:
https://github.com/lukefx/rack-ntlm
https://github.com/rekado/ntlm-sso
Note that both projects are pretty thinly maintained; depending on the
Rails version you’re targeting, you may need to roll your own solution
instead.
Also note that NTLM hands you information that is totally under the
end-user’s control: you’ll need to verify the information with an Active
Directory server if you want to have any confidence in the values.
rack-ntlm appears to do this, but ntlm-sso does not.
If Possible… please attach the sample code for more reference.
That’s not really how this list works: you’ll get a much better response
if
you can say, “here’s what I’ve tried, and this is how it’s not working”
instead of “GIVE ME CODEZ PLZ”.
–Matt J.
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.
Sponsor our Newsletter | Privacy Policy | Terms of Service | Remote Ruby Jobs