473,402 Members | 2,055 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,402 software developers and data experts.

Changing User Password - Credential Problem

I'm trying to change a user's password using objUser.Invoke("setPassword",
"newpassword")

It works fine as a console application if I'm logged in with someone with
the correct permissions. If I'm logged in as a normal user it doesn't work,
even though call before that,

objUser.Username = "ad***@domain.com"
objUser.Password = "adminpassword"

Obviously the ASP.NET account doesn't have permissions to change passwords
so how can I escalate my permissions for this one task?

-
Steve Evans
Email Services
SDSU Foundation
Nov 18 '05 #1
4 2313
you should have the user pass the old password, then impersonate them, then
change password to new password., otherwise you need to impersonate a domain
admin
-- bruce (sqlwork.com)
"- Steve -" <se****@foundation.sdsu.edu> wrote in message
news:eC**************@tk2msftngp13.phx.gbl...
I'm trying to change a user's password using objUser.Invoke("setPassword",
"newpassword")

It works fine as a console application if I'm logged in with someone with
the correct permissions. If I'm logged in as a normal user it doesn't work, even though call before that,

objUser.Username = "ad***@domain.com"
objUser.Password = "adminpassword"

Obviously the ASP.NET account doesn't have permissions to change passwords
so how can I escalate my permissions for this one task?

-
Steve Evans
Email Services
SDSU Foundation

Nov 18 '05 #2
This is for admins to reset users forgotten passwords, etc. So I don't know
the existing password of the account.

How can I impersonate another account? Preferably how do I get it to
execute under the context of the user that logged into IIS (it's protected
with basic authentication)

--

Steve Evans
Email Services
SDSU Foundation
"bruce barker" <no***********@safeco.com> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl...
you should have the user pass the old password, then impersonate them, then change password to new password., otherwise you need to impersonate a domain admin
-- bruce (sqlwork.com)
"- Steve -" <se****@foundation.sdsu.edu> wrote in message
news:eC**************@tk2msftngp13.phx.gbl...
I'm trying to change a user's password using objUser.Invoke("setPassword", "newpassword")

It works fine as a console application if I'm logged in with someone with the correct permissions. If I'm logged in as a normal user it doesn't

work,
even though call before that,

objUser.Username = "ad***@domain.com"
objUser.Password = "adminpassword"

Obviously the ASP.NET account doesn't have permissions to change passwords so how can I escalate my permissions for this one task?

-
Steve Evans
Email Services
SDSU Foundation


Nov 18 '05 #3
ASP.NET application for impersonate an account (if IIS have not Anonimous
access) must have a key in Web.Config. This key is Impersonate and the value
must be true.
In this way ASP.NET application have your permission on the machine and I
think that you can do what you want. User property of ASP.NET page can help
you for know logged user.

Brun

"- Steve -" <se****@foundation.sdsu.edu> wrote in message
news:%2***************@TK2MSFTNGP09.phx.gbl...
This is for admins to reset users forgotten passwords, etc. So I don't know the existing password of the account.

How can I impersonate another account? Preferably how do I get it to
execute under the context of the user that logged into IIS (it's protected
with basic authentication)

--

Steve Evans
Email Services
SDSU Foundation
"bruce barker" <no***********@safeco.com> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl...
you should have the user pass the old password, then impersonate them,

then
change password to new password., otherwise you need to impersonate a

domain
admin
-- bruce (sqlwork.com)
"- Steve -" <se****@foundation.sdsu.edu> wrote in message
news:eC**************@tk2msftngp13.phx.gbl...
I'm trying to change a user's password using objUser.Invoke("setPassword", "newpassword")

It works fine as a console application if I'm logged in with someone with the correct permissions. If I'm logged in as a normal user it doesn't

work,
even though call before that,

objUser.Username = "ad***@domain.com"
objUser.Password = "adminpassword"

Obviously the ASP.NET account doesn't have permissions to change passwords so how can I escalate my permissions for this one task?

-
Steve Evans
Email Services
SDSU Foundation



Nov 18 '05 #4
ASP.NET application for impersonate an account (if IIS have not Anonimous
access) must have a key in Web.Config. This key is Impersonate and the value
must be true.
In this way ASP.NET application have your permission on the machine and I
think that you can do what you want. User property of ASP.NET page can help
you for know logged user.

Brun

"- Steve -" <se****@foundation.sdsu.edu> wrote in message
news:%2***************@TK2MSFTNGP09.phx.gbl...
This is for admins to reset users forgotten passwords, etc. So I don't know the existing password of the account.

How can I impersonate another account? Preferably how do I get it to
execute under the context of the user that logged into IIS (it's protected
with basic authentication)

--

Steve Evans
Email Services
SDSU Foundation
"bruce barker" <no***********@safeco.com> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl...
you should have the user pass the old password, then impersonate them,

then
change password to new password., otherwise you need to impersonate a

domain
admin
-- bruce (sqlwork.com)
"- Steve -" <se****@foundation.sdsu.edu> wrote in message
news:eC**************@tk2msftngp13.phx.gbl...
I'm trying to change a user's password using objUser.Invoke("setPassword", "newpassword")

It works fine as a console application if I'm logged in with someone with the correct permissions. If I'm logged in as a normal user it doesn't

work,
even though call before that,

objUser.Username = "ad***@domain.com"
objUser.Password = "adminpassword"

Obviously the ASP.NET account doesn't have permissions to change passwords so how can I escalate my permissions for this one task?

-
Steve Evans
Email Services
SDSU Foundation



Nov 18 '05 #5

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

Similar topics

0
by: Jason Jodon | last post by:
I am trying to change the value of the Qty field in this cXML stream to reflect the value the user enters in the Qty field. Our programmer showed me this in XML using Microsoft.XMLDOM, but the...
0
by: dee | last post by:
Hi, This might be a very simple one but I havn't been able to get it working. I have Impersonate to be ON in web.config file. I have sections of application that impersonate as someone other and...
10
by: Fabrizio | last post by:
(Sorry for the crosspost, but I really don't know which is the right newsgroup!) Hi all, I try to change the password to a user that as to change the password at first logon: try {
3
by: - Steve - | last post by:
I'm trying to change a user's password using objUser.Invoke("setPassword", "newpassword") It works fine as a console application if I'm logged in with someone with the correct permissions. If...
0
by: Hari potter | last post by:
Hi all, I have an asp.net website that references some dlls. The web site has been configured to use anonymous access(with windows credential user name and password) and also Windows...
9
by: webrod | last post by:
Hi all, how can I check a user/password in a LDAP ? I don't want to connect with this user, I would like to connect to LDAP with a ADMIN_LOG/ADMIN_PWD, then do a query to find the user and...
2
by: sweetpotatop | last post by:
Hi, I wonder how can I get the window/network credential from the user machine thru' ASP.NET? I have been using LDAP, however, the user will be prompted for username and password at least...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
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
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
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
tracyyun
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...
0
isladogs
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...

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.