Skip to content

Instantly share code, notes, and snippets.

@rayedchan
rayedchan / GenerateRequestTestDriver.java
Last active February 1, 2023 23:03
Generate requests using Oracle Identity Manager API
package com.blogspot.oraclestack.testdriver;
import com.blogspot.oraclestack.services.OracleIdentityManagerClient;
import com.blogspot.oraclestack.utilities.GenerateRequestUtilities;
import java.util.HashMap;
import oracle.iam.platform.OIMClient;
import oracle.iam.vo.OperationResult;
/**
* Test Driver for GenerateRequestUtilities class
@rayedchan
rayedchan / CondPostEHMetadata.xml
Created January 18, 2015 06:08
Conditional PostProcess Event Handler
<?xml version="1.0" encoding="UTF-8"?>
<eventhandlers xmlns="http://www.oracle.com/schema/oim/platform/kernel" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.oracle.com/schema/oim/platform/kernel orchestration-handlers.xsd">
<action-handler
entity-type="User"
operation="CREATE"
class="com.blogspot.oraclestack.eventhandlers.ConditionalEventHandlerPostProcess"
name="ConditionalEventHandlerPostProcess"
stage="postprocess" order="1050"
sync="TRUE"/>
</eventhandlers>
@rayedchan
rayedchan / JarElementType.java
Last active August 29, 2015 14:15
JAR Utility for Oracle Identity Manager
package com.blogspot.oraclestack.constants;
/**
* Represents all the possible jar types for the UploadJars.sh utility.
* @author rayedchan
*/
public enum JarElementType
{
JavaTasks, ScheduleTasks, ThirdParty, ICFBundle;
}
@rayedchan
rayedchan / PrepopulateAdapters.java
Created February 15, 2015 02:41
OIM Prepopulate Adapters: Java Code
package com.blogspot.oraclestack.adapters;
import oracle.core.ojdl.logging.ODLLevel;
import oracle.core.ojdl.logging.ODLLogger;
/**
* Contain methods for prepopulate adapters. These adapters are used to populate
* the process form instance of a resource account. In Oracle Identity Manager,
* Prepopulate adapters are executed on the initial assignment of a resource account to a user.
* @author rayedchan
@rayedchan
rayedchan / ReconciliationEvents.java
Last active August 29, 2015 14:17
OIM API: Create Reconciliation Event (Parent Data Only)
package com.blogspot.oraclestack.utilities;
import Thor.API.Exceptions.tcAPIException;
import java.util.Date;
import java.util.HashMap;
import oracle.core.ojdl.logging.ODLLevel;
import oracle.core.ojdl.logging.ODLLogger;
import oracle.iam.platform.OIMClient;
import oracle.iam.reconciliation.api.ChangeType;
import oracle.iam.reconciliation.api.EventAttributes;
@rayedchan
rayedchan / BulkModifyUserEHPostProcess.java
Created March 21, 2015 04:45
OIM Event Handler: Implement Execute for Bulk Orchestration
package com.blogspot.oraclestack.eventhandlers;
import java.io.Serializable;
import java.util.HashMap;
import java.util.HashSet;
import oracle.core.ojdl.logging.ODLLevel;
import oracle.core.ojdl.logging.ODLLogger;
import oracle.iam.identity.exception.NoSuchUserException;
import oracle.iam.identity.exception.UserLookupException;
import oracle.iam.identity.usermgmt.api.UserManager;
@rayedchan
rayedchan / EntitlementTestDriver.java
Created March 31, 2015 03:37
OIM API: Entitlements
package com.blogspot.oraclestack.testdriver;
import com.blogspot.oraclestack.utilities.EntitlementUtilities;
import java.util.Date;
import java.util.HashMap;
import java.util.Hashtable;
import oracle.iam.identity.usermgmt.api.UserManager;
import oracle.iam.platform.OIMClient;
import oracle.iam.provisioning.api.EntitlementService;
import oracle.iam.provisioning.api.ProvisioningService;
@rayedchan
rayedchan / ProvisioningTestDriver.java
Last active January 19, 2024 21:12
OIM API: Provisioning Resource Account to User
package com.blogspot.oraclestack.testdriver;
import com.blogspot.oraclestack.utilities.ProvisioningUtils;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.Hashtable;
import java.util.Map;
import oracle.core.ojdl.logging.ODLLogger;
import oracle.iam.platform.OIMClient;
import oracle.iam.provisioning.vo.ChildTableRecord.ACTION;
@rayedchan
rayedchan / ProvAppInstPreEHMetadata.xml
Created June 16, 2015 02:54
Event Handler Example: Application Instance
<?xml version="1.0" encoding="UTF-8"?>
<eventhandlers xmlns="http://www.oracle.com/schema/oim/platform/kernel" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.oracle.com/schema/oim/platform/kernel orchestration-handlers.xsd">
<action-handler
entity-type="ApplicationInstance"
operation="PROVISION"
class="com.blogspot.oraclestack.eventhandlers.ProvisionAppInstancePreProcess"
name="ProvisionAppInstancePreProcess"
stage="preprocess"
order="1"
sync="TRUE"/>
@rayedchan
rayedchan / FetchFromCredentialStore.java
Created June 19, 2015 04:28
Credential Store Framework (CSF) API Example
package com.blogspot.oraclestack.scheduledtasks;
import java.security.AccessController;
import java.security.PrivilegedActionException;
import java.security.PrivilegedExceptionAction;
import java.util.HashMap;
import java.util.Map;
import oracle.core.ojdl.logging.ODLLevel;
import oracle.core.ojdl.logging.ODLLogger;
import oracle.iam.scheduler.vo.TaskSupport;