Just Enough Administration (JEA) Configuration

Implementing least-privilege administration in Active Directory

What is Just Enough Administration (JEA)?

Just Enough Administration (JEA) is a security technology that enables delegated administration for anything managed by PowerShell. JEA uses PowerShell's Remoting and Constrained Endpoints to reduce risk by limiting what users can do.

Benefits of JEA

JEA Configuration Steps

  1. 1. Enable PowerShell Remoting

    Run the following command in an elevated PowerShell prompt:

    Enable-PSRemoting -Force
  2. 2. Create a JEA Role Capability File

    Create a new PowerShell script file with a .psrc extension, for example:

    New-PSRoleCapabilityFile -Path "C:\JEA\ADUserManagement.psrc"

    Edit the file to define allowed cmdlets, functions, and parameters.

  3. 3. Create a JEA Session Configuration File

    Create a PowerShell session configuration file:

    New-PSSessionConfigurationFile -Path "C:\JEA\ADUserManagement.pssc"

    Edit the file to specify role definitions and session settings.

  4. 4. Register the JEA Configuration

    Register the session configuration:

    Register-PSSessionConfiguration -Path "C:\JEA\ADUserManagement.pssc" -Name "ADUserManagement" -Force
  5. 5. Grant Users Access to the JEA Endpoint

    Use Set-PSSessionConfiguration to grant users or groups access:

    Set-PSSessionConfiguration -Name "ADUserManagement" -ShowSecurityDescriptorUI
Tip: Always test your JEA configurations in a non-production environment before deploying to production.

Example: JEA for Active Directory User Management

Here's a basic example of a role capability file for AD user management:

@{
  VisibleCmdlets = @(
    'Get-ADUser',
    @{ Name = 'Set-ADUser'; Parameters = @{ Name = 'GivenName'; ValidateSet = @('*') } },
    @{ Name = 'Set-ADUser'; Parameters = @{ Name = 'Surname'; ValidateSet = @('*') } },
    'Unlock-ADAccount'
  )
  VisibleFunctions = 'Get-ADUserStatus'
}
  

This configuration allows users to view AD users, change first and last names, and unlock accounts.

Best Practices for JEA

Troubleshooting JEA

Warning: Be cautious when granting access to powerful cmdlets. Always test thoroughly to ensure the principle of least privilege is maintained.





Scroll to Top