473,505 Members | 15,798 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

win form security

I would like to authenticate to windows via a login creen in my application.
when i do a search I get stuff but on asp. This is not for asp.net I just
what a login screen for win form applications that will check the username
and password entered in a login screen against windows local or on a server.
Nov 16 '05 #1
1 1083
freddy,

Basically, you are going to have to call the LogonUser or LogonUserEx
function in the API through the P/Invoke layer. It will validate the user
and the password. You can also impersonate the user logged in (which you
should, for certain permissions) by using the WindowsIdentity class (check
the documnetation for the Impersonate method on the WindowsIdentity class to
see how).

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"freddy" <fr****@discussions.microsoft.com> wrote in message
news:0B**********************************@microsof t.com...
I would like to authenticate to windows via a login creen in my
application.
when i do a search I get stuff but on asp. This is not for asp.net I just
what a login screen for win form applications that will check the username
and password entered in a login screen against windows local or on a
server.

Nov 16 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
1363
by: dvorett | last post by:
I have a form in my database that is password protected, and several forms contain buttons that open the password protected page. Each button asks for the password, but I dont want access to ask...
7
3620
by: | last post by:
I am having trouble figuring out to call a database INSERT procedure from a simple submit form. It appears I should use the onclick event to trigger the procedure called BUT when I do this I...
27
2561
by: Scott | last post by:
I've been trying to come up with a way to ensure user input is coming from the form on my site, and not auto-submitted from elsewhere, and I don't want to use the "enter the code shown in the...
6
2635
by: Spycat | last post by:
Hi all and happy holidays! I should start off by stating I am NOT a PHP programmer. I say that so that in any response to me, you will speak very s-l-o-w-l-y or I won't know what you're talking...
7
5731
by: Parasyke | last post by:
Can anyone coach me in a custom log-in screen? I have a table set up with users and a password. So basically the user sign in form would authenticate the user and password (IF - Then). What I need...
0
7218
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7103
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7307
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7370
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
7021
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
4701
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3177
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1532
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
0
409
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.