impersonate problem

From: AJang (AJang_at_discussions.microsoft.com)
Date: 09/07/05


Date: Wed, 7 Sep 2005 01:28:03 -0700

Scenario:
  1. IIS anonymous authentication turnned on
  2. Web.config contained:
         <authentication mode="Windows" />
          <identity impersonate="true" userName="localuser" password="real
password" />
  3. In Web application form , guest fill data and updated to backend
database, whcich is an mdb file.

Every thing is ok when "localuser" is in Administrators group.
For minimum privileges principle, I change "localuser" to "Power users"
group, the web application encounter error with following stack:
===================================
[OleDbException (0x80004005): 無法指出的錯誤]
   System.Data.OleDb.OleDbConnection.ProcessResults(Int32 hr) +20
   System.Data.OleDb.OleDbConnection.InitializeProvider() +57
   System.Data.OleDb.OleDbConnection.Open() +203
   System.Data.Common.DbDataAdapter.QuietOpen(IDbConnection connection,
ConnectionState& originalState) +44
   System.Data.Common.DbDataAdapter.FillFromCommand(Object data, Int32
startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
CommandBehavior behavior) +304
   System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32 startRecord,
Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior
behavior) +77
   System.Data.Common.DbDataAdapter.Fill(DataSet dataSet) +38
   WebSec.WebForm1.Page_Load(Object sender, EventArgs e) in
c:\inetpub\wwwroot\websec\webform1.aspx.cs:35
   System.Web.UI.Control.OnLoad(EventArgs e) +67
   System.Web.UI.Control.LoadRecursive() +35
   System.Web.UI.Page.ProcessRequestMain() +750
==================================

I think that is a kind of "not enough permission", but how to fix it.

thanks.

Ajang
   



Relevant Pages

  • Error Trying to Launch Project
    ... startRecord, Int32 maxRecords, String srcTable, IDbCommand command, ... CommandBehavior behavior) at System.Data.Common.DbDataAdapter.Fill(DataSet ... dataSet, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand ...
    (microsoft.public.dotnet.distributed_apps)
  • ThreadAbortException at System.Data.SqlClient.SqlCommand.ExecuteRe (BIS)
    ... startRecord, Int32 maxRecords, String srcTable, IDbCommand command, ... CommandBehavior behavior) ...
    (microsoft.public.dotnet.framework.adonet)
  • ThreadAbortException at System.Data.SqlClient.SqlCommand.ExecuteRe
    ... When i launch the same code sometimes it never crash a the same place but ... startRecord, Int32 maxRecords, String srcTable, IDbCommand command, ... CommandBehavior behavior) ...
    (microsoft.public.dotnet.framework.adonet)
  • datagrid error
    ... Server]Line 1: Incorrect syntax near '.'.] ... startRecord, Int32 maxRecords, String srcTable, IDbCommand command, ... CommandBehavior behavior) +77 ...
    (microsoft.public.dotnet.framework.aspnet)
  • ANONMOUS LOGIN
    ... startRecord, Int32 maxRecords, String srcTable, IDbCommand command, ... CommandBehavior behavior) at System.Data.Common.DbDataAdapter.Fill(DataSet ... dataSet, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand ...
    (microsoft.public.inetserver.asp.db)

Quantcast