Security Testing – Debugging when using restricted roles

Step 1:
Add the roles that you would like to test to your own user.
You also need to give yourself the role System administrator.
Step 2:
Open the development workspace.
Step 3:
Create a job and add following code.

static void nonAdminMode(Args _args)
{
    SecurityUtil::sysAdminMode(false);
}

Step 4:
Ctrl + W will open the workspace where you can simulate the issue.
At this moment you have reduced rights but you still have the possibility to debug.
Step 5:
When done testing & debugging close the session and run following job.

static void adminMode(Args _args)
{
    SecurityUtil::sysAdminMode(true);
}
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s