IT Audit: Scan for Unauthorized PII in a User's Personal Caslib - WeAreCAS
accessControlaccessPersonalCaslibs
IT Audit: Scan for Unauthorized PII in a User's Personal Caslib
Scénario de test & Cas d'usage
Contexte Métier
An internal data governance policy prohibits storing sensitive Personally Identifiable Information (PII) in personal CAS workspaces. An IT administrator must perform a spot audit on a specific user's personal caslib (`CASUSER(finance_user)`) to check for non-compliant data without disrupting the user's session.
Préparation des Données
Simulate a scenario where 'finance_user' has loaded two tables into their personal caslib: one compliant ('quarterly_sales') and one non-compliant ('employee_pii') containing sensitive data. This setup requires admin rights to place tables in another user's caslib.
Copié !
/* Data setup requires admin privileges */
proc cas;
/* Simulate finance_user's data */
data casuser(finance_user).employee_pii(promote=yes);
length ssn $11 name $50;
ssn='123-45-678'; name='John Doe'; output;
ssn='987-65-432'; name='Jane Smith'; output;
run;
data casuser(finance_user).quarterly_sales(promote=yes);
length product $20;
product='Widget A'; sales=15000; output;
product='Widget B'; sales=22000; output;
run;
quit;
1
/* Data setup requires admin privileges */
2
PROCCAS;
3
/* Simulate finance_user's data */
4
DATA casuser(finance_user).employee_pii(promote=yes);
5
LENGTH ssn $11 name $50;
6
ssn='123-45-678'; name='John Doe'; OUTPUT;
7
ssn='987-65-432'; name='Jane Smith'; OUTPUT;
8
RUN;
9
10
DATA casuser(finance_user).quarterly_sales(promote=yes);
11
LENGTH product $20;
12
product='Widget A'; sales=15000; OUTPUT;
13
product='Widget B'; sales=22000; OUTPUT;
14
RUN;
15
QUIT;
Étapes de réalisation
1
Baseline Check: As an administrator, attempt to list tables in 'CASUSER(finance_user)'. This step is expected to fail with an authorization error, proving that access is initially restricted.
Copié !
proc cas;
/* This will fail as access is not yet granted */
table.tableInfo / caslib="CASUSER(finance_user)";
run;
1
PROCCAS;
2
/* This will fail as access is not yet granted */
3
TABLE.tableInfo / caslib="CASUSER(finance_user)";
4
RUN;
2
Privilege Escalation: Execute the accessPersonalCaslibs action to gain administrative access to all personal caslibs for the current session.
The administrator successfully lists and inspects tables within another user's personal caslib after executing the action. The initial attempt fails due to lack of permissions, while the subsequent attempts succeed, confirming the action correctly elevates privileges for targeted administrative tasks.