Solved

RAS Logging automatically

Posted on 1998-08-21
3
240 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 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

Instantly Create Instructional Tutorials

Contextual Guidance at the moment of need helps your employees adopt to new software or processes instantly. Boost knowledge retention and employee engagement step-by-step with one easy solution.

Question has a verified solution.

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

Suggested Solutions

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…
As more and more people are shifting to the latest .Net frameworks, the windows presentation framework is gaining importance by the day. Many people are now turning to WPF controls to provide a rich user experience. I have been using WPF controls fo…
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…

732 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