I'm trying to setup a web site that uses active directory for user
authentication under asp.net 2.0.
For testing, I have separately installed two virtual servers. The first is
a domain controller in a new forest named VSERVER00 running Windows Server
2003 R2 Standard. The second is an application server running IIS in the
same domain, named VSERVER01 also running Windows Server 2003 R2 Standard.
The domain is VDOMAIN.local.
I have created an OU called Test in Active Directory on VSERVER00 and used
the Delegation of Control Wizard to grand all permissions to the
Administrator account. To keep this simple, the administrator is
administrator with the password password. I've created one user in the OU
manually through the GUI.
The IIS server Web.config page is configured as shown below.
----------
<?xml version="1.0" encoding="utf-8"?>
<configuratio n xmlns="http://schemas.microso ft.com/.NetConfigurati on/v2.0">
<connectionStri ngs>
<add name="vDomainAc tiveDirectory"
connectionStrin g="LDAP://VSERVER00/OU=Test,DC=VDOM AIN,DC=local" />
</connectionStrin gs>
<system.web>
<customErrors mode="Off" />
<authenticati on mode="Forms" />
<authorizatio n>
<allow roles="admin" />
</authorization>
<membership defaultProvider ="AspNetActiveD irectoryMembers hipProvider">
<providers>
<add name="AspNetAct iveDirectoryMem bershipProvider "
connectionStrin gName="vDomainA ctiveDirectory"
applicationName ="/"
maxInvalidPassw ordAttempts="5"
passwordAttempt Window="8"
attributeMapUse rname="sAMAccou ntName"
connectionProte ction="None"
connectionUsern ame="vDOMAIN\Ad ministrator"
connectionPassw ord="password"
minRequiredPass wordLength="6"
minRequiredNona lphanumericChar acters="0"
enablePasswordR eset="false"
enableSearchMet hods="true"
requiresQuestio nAndAnswer="fal se"
requiresUniqueE mail="false"
type="System.We b.Security.Acti veDirectoryMemb ershipProvider,
System.Web, Version=2.0.0.0 , Culture=neutral , PublicKeyToken= b03f5f7f11d50a3 a"
/>
</providers>
</membership>
<roleManager enabled="false" />
</system.web>
</configuration>
----------
Then I created a virtual folder on the application server named
TestCreateUser. On my computer, I created a very simple web application
using Visual Studio 2005 using the CreateUserWizar d control and copied it to
the virtual folder.
In the web application, I have not written any custom code, only configured
the control (completely in the ascx file). Below is the ASCX file.
----------
<%@ Page Language="C#" AutoEventWireup ="true" CodeFile="Defau lt.aspx.cs"
Inherits="_Defa ult" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dt d">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>New User Creation - test page</title>
</head>
<body>
<form id="frmNewUser " runat="server">
<div>
<asp:CreateUser Wizard ID=wizNewUser runat="server">
<WizardSteps>
<asp:CreateUser WizardStep runat="server">
</asp:CreateUserW izardStep>
<asp:CompleteWi zardStep runat="server">
</asp:CompleteWiz ardStep>
</WizardSteps>
</asp:CreateUserW izard>
</div>
</form>
</body>
</html>
----------
The first time into the page, I can create a new user without any problems.
All subsequent attempts at creating a new user fail with the following error.
----------
Server Error in '/TestCreateUser' Application.
--------------------------------------------------------------------------------
One or more input parameters are invalid
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information about
the error and where it originated in the code.
Exception Details: System.Runtime. InteropServices .COMException: One or more
input parameters are invalid
Source Error:
An unhandled exception was generated during the execution of the current web
request. Information regarding the origin and location of the exception can
be identified using the exception stack trace below.
Stack Trace:
[COMException (0x80005008): One or more input parameters are invalid]
[TargetInvocatio nException: Exception has been thrown by the target of an
invocation.]
System.Director yServices.Direc toryEntry.Invok e(String methodName,
Object[] args) +221
System.Web.Secu rity.ActiveDire ctoryMembership Provider.Create User(String
username, String password, String email, String passwordQuestio n, String
passwordAnswer, Boolean isApproved, Object providerUserKey ,
MembershipCreat eStatus& status) +2461
System.Web.UI.W ebControls.Crea teUserWizard.At temptCreateUser () +305
System.Web.UI.W ebControls.Crea teUserWizard.On NextButtonClick (WizardNavigati onEventArgs e) +105
System.Web.UI.W ebControls.Wiza rd.OnBubbleEven t(Object source, EventArgs
e) +453
System.Web.UI.W ebControls.Crea teUserWizard.On BubbleEvent(Obj ect source,
EventArgs e) +149
System.Web.UI.W ebControls.Wiza rdChildTable.On BubbleEvent(Obj ect source,
EventArgs args) +17
System.Web.UI.C ontrol.RaiseBub bleEvent(Object source, EventArgs args) +35
System.Web.UI.W ebControls.Butt on.OnCommand(Co mmandEventArgs e) +115
System.Web.UI.W ebControls.Butt on.RaisePostBac kEvent(String eventArgument)
+163
System.Web.UI.W ebControls.Butt on.System.Web.U I.IPostBackEven tHandler.RaiseP ostBackEvent(St ring eventArgument) +7
System.Web.UI.P age.RaisePostBa ckEvent(IPostBa ckEventHandler
sourceControl, String eventArgument) +11
System.Web.UI.P age.RaisePostBa ckEvent(NameVal ueCollection postData) +33
System.Web.UI.P age.ProcessRequ estMain(Boolean
includeStagesBe foreAsyncPoint, Boolean includeStagesAf terAsyncPoint) +5102
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.507 27.42; ASP.NET
Version:2.0.507 27.42
----------
If I reset IIS, I am able to create another user, then as before, all
subsequent submissions fail with the same error.
What am I missing? -- Help 0 1625 This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Rik Brooks |
last post by:
I am trying to write a change password routine using the new
ActiveDirectoryMembershipProvider. My code is below. I'm getting an exception
saying that my ActiveDirectoryMembershipProvider has not been initialized.
Can you guys point me to something that tells me what I'm doing wrong, please?
bool checkItOut;
string ls_retVal = "";
ActiveDirectoryMembershipProvider obj = new
ActiveDirectoryMembershipProvider();
try
|
by: Learner |
last post by:
Hello,
I have defined another textbox control in the CreateUserWizard
control and this is how I am trying to get the value of it in the code
behind page is below
im myStep As CreateUserWizardStep = New CreateUserWizardStep
Dim DealerShipIDvalue As TextBox =
myStep.ContentTemplateContainer.FindControl("_txtDealerShipID")
Dim dealer As String
dealer = Server.HtmlEncode(DealerShipIDvalue.Text)
|
by: JD Qixcle |
last post by:
I have been following several threads between David Thielen and Luke Zhang
regarding the ActiveDirectoryMembershipProvider as used for ASP.NET
2.0 Forms authentication, but I receive a slighly different error. I
consistently receive the following message after submitting credentials from
the login page:
Parser Error Message: Object reference not set to an instance of an object.
Source Error:
|
by: Parag Mahajan |
last post by:
Hi,
I am using the membership provider class, "System.Web.Security.ActiveDirectoryMembershipProvider".
I am using Login Server control and attaching the already configured "ActiveDirectoryMembershipProvider" in the web.config file. But my restriction is that I do not want to give the "connectionUsername" and "connectionPassword" in the web.config file.
I want to update this 2 attributes at runtime in the Login1_LoggingIn event handler, so...
|
by: Glenn Eastlack |
last post by:
I have been trying to use ASP.NET 2.0 built-in Membership Providers.
Particularly the ActiveDirectoryMembershipProvider.
My web.config looks like this:
<connectionStrings>
<clear/>
<add name="ADConnectionString"
connectionString="LDAP://192.168.32.129/CN=users,CN=testdns,DC=test,DC=com"
/>
</connectionStrings>
| |
by: Avi |
last post by:
A CreateUserWizard contorl receives new user details, adds the user to
the database, tries to send a confirmation mail message and stops with
a "System.FormatException: The specified string is not in the form
required for an e-mail address."
Any ideas?
---------------------------------------------------------
The CreateUserWizard contorl's code:
|
by: zeplynne |
last post by:
Having trouble using ActiveDirectoryMembershipProvider with one specific
website. When attempting to login to the site, after a long period of time
(about 2 - 3 minutes), "Server Application Unavailable" message is returned.
If I switch the provider back to SQLServer everything works fine.
If I create a new simple Web Application and just add a Login.aspx page and
Default.aspx page, and nothing else, and add a Login Control everything...
|
by: rroden |
last post by:
C:\WINDOWS\assembly
\WindowsSystem.Web.Security.ActiveDirectoryMembershipProvider isn't
being installed with .net 2.0 or 3.0 on any of my systems. What am I
doing wrong?
|
by: Max2006 |
last post by:
Hi,
I am using ActiveDirectoryMembershipProvider for authentication. In my
development environment I don't have any Active Directory available for
development and test. Basically my development environment is a windows xp
laptop.
I am trying to avoid running a domain controller on my laptop. What would
be the easiest way to develop and test my application without running a
domain controller on my laptop?
|
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
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 we have to send another system
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
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 can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |