Solved

RAS Logging automatically

Posted on 1998-08-21
3
224 Views
Last Modified: 2013-12-03
When RAS authenticates the user who wants to log on to the NT network ,(of course he has a account in the NT network), a login dialogue appears which requests user's password (but I've pass the user's password in calling rasdial API). How can I get hold of the login dialogue in my program so as to pass the password to NT authentication and log onto tne network ? Any help is appreciated.
0
Comment
Question by:wuxie
  • 2
3 Comments
 
LVL 1

Accepted Solution

by:
fmismetti earned 200 total points
ID: 1413780
Create a Dial profile using the dial up, including phone number, DNS stuff and all.

Fill an structure RASDIALPARAMS, where szEntryName is the name of the dial up profile you created. Suply the fields szUserName and szPassword.

Call the Win32 function RasDial, passing your structure as parameter number 3.

After that, look for messages WM_RASDIALEVENT to determine the conection status.

Good luck.

0
 

Author Comment

by:wuxie
ID: 1413781
My question refers to logging  onto the NT network so that the remote user can use shared resource; I've tried RasDial API,but it doesn't log the user onto the network really in NT,except that  you manully fill the dialogue it calls for example, the  password. I want to find a way to get rid of the logon dialogue so I can control the logon instead of typing something while I'm logging so I can login automatically..  
0
 
LVL 1

Expert Comment

by:fmismetti
ID: 1413782
In the configuration of the DialUp profile, in the server types tab you have a "Log on the network" check box. Turn this on. Also, turn on and configure all the protocols you want to use.

When RAS get connected, it applies all the options that you have setup in the profile (you pass the profile name in the RASDIALPARAMS.szEntryName field) and uses RASDIALPARAMS.szUserName RASDIALPARAMS.szPassword to log on the network.

I used this method in several configurations, and logging on to the network it was not a problem, accessing resources by TCP/IP or Netbeui. After the dial, I receive a message "RASCS_Authenticate" (begin of authentication) and after a few seconds, "RASCS_Authenticated" (authentication OK).

Hope it help you. If no, you can always reject the answer to see if someone has another way to do this.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
display png images in VB6 4 381
Slow process to read Excel 15 112
WPF - External data binding to controls inside a UserControl 2 54
VS2015 Redefinition errors 4 29
This article describes how to programmatically preset the "Pages per Sheet" option that's available with most printer drivers.   This setting lets you do "n-Up" printing, where two, four, or more pages are printed on each sheet of paper. If your …
This article surveys and compares options for encoding and decoding base64 data.  It includes source code in C++ as well as examples of how to use standard Windows API functions for these tasks. We'll look at the algorithms — how encoding and decodi…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
Both in life and business – not all partnerships are created equal. As the demand for cloud services increases, so do the number of self-proclaimed cloud partners. Asking the right questions up front in the partnership, will enable both parties …

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now