1

Closed

CheckAccessHelper: Add overloads for IAzManDBUser type

description

From: cmacholz
I guess you missed my question....I'm am doing exactly what is in this link http://netsqlazman.codeplex.com/Thread/View.aspx?ThreadId=50769 (Which is good) But upon reading your documentation I noticed another more streamlined way to checkAccess, the CheckAccessHelper class(*1). The cool thing about the Helper class, is it auto generates your Roles, Tasks, and Operations ENUM's for you. But it does Not take a IAzManDBUser in the constructor and all of the codes (*2) overridden method signatures do not take a IAzManDBUser, but a DBuserName as string. I've Written my own "Helper" class, but the auto-generated code would be easier to maintain. If the "Generate CheckAccesHelper" fucntion also included overided methods that took a IAzmanDBUser I wouldn't have to manually update my roles, tasks, and operations Enum (Which I  will spell wrong and wonder why its not working).
 
So, Could you add another overriden CheckAccess function to your helper classes that takes a IAzManDBUser?
 
if, not, no big deal, I'll just manually upadate my own helper class.
 
Thanks
 
 
1) #######################
string cs = "data source=eidosis4-afr;Initial
Catalog=NetSqlAzManStorage;Integrated Security = SSPI;";
My_Application.Security.CheckAccessHelper helper = new
My_Application.Security.CheckAccessHelper(cs, WindowsIdentity.GetCurrent());
 
helper.OpenConnection();
 
bool result = helper.CheckAccess(My_Application.Security.CheckAccessHelper.Operation.Op1);
helper.CloseConnection();
 
//Use result for your business logic
if (result == true)
{
//Allow or AllowWithDelegation
}
else
{
//Deny or Neutral
}
 
 

END 1)

 

2)

 
Public Overridable Overloads Function GetAuthorizationType
Protected Overridable Overloads Function CheckAccess
 

End 2

Closed Mar 28, 2009 at 4:25 AM by aferende

comments

wrote Mar 28, 2009 at 4:25 AM

Resolved with changeset 20181.