Configure CrowdStrike
Overview
Everything on the CrowdStrike side happens before Britive is touched. You need an API client for Britive to authenticate with, and the elevation scripts stored in Falcon where RTR can execute them.
Do the role check first. It is the step that most often stops a setup halfway through.
Before You Begin
- Falcon administrator access.
- Falcon Insight or Falcon Enterprise licensing, with RTR support.
- The elevation scripts from britive/access-broker-examples, or your own equivalents:
- README.md
- elevate.ps1
- de-elevate.ps1
- elevate.sh
- de-elevate.sh
Grant yourself the RTR Admin role before you start. Uploading a custom RTR script requires the RTR Admin role on your own Falcon user account. It is separate from the API client scopes below — giving the API client RTR Admin does not give it to you. Administrators regularly complete the whole integration and then find they cannot upload the scripts to finish it.
Steps
Give your Falcon user the RTR Admin role
In Falcon, open Host setup and management → User management, find your own user, and confirm it holds Real Time Response Admin. Add it if not.
Without it, the script upload in step 4 is unavailable.
Create the API client
Go to Support and resources → API clients and keys, then Create API client. Give it a name that identifies it as Britive’s, so it is obvious later what breaks if it is revoked.
Grant these scopes:
| Scope | Access | Why |
|---|---|---|
| Hosts | Read | Discover the devices to elevate on |
| Real Time Response | Write | Execute the elevation and revocation scripts |
| Real Time Response Admin | Write | Optional — lets the scan collect your script list |
| Response Policies | Read | Read the response policies applied to hosts |
| User Management | Read | Resolve accounts for mapping |
Grant nothing beyond these. The client can execute scripts on every endpoint in scope, which makes it a high-value credential.
Real Time Response Admin is only used for discovery. The scan needs it to read back the list of scripts in your Falcon tenant. Executing a script needs Real Time Response: Write alone.
Leave it out and elevation still works — you simply will not see your scripts on the integration’s Permissions tab, and will have to enter their names with Type Manually when building profiles. That is a reasonable trade if your security team would rather not grant it.
Record the connection values
Falcon shows the client secret once. Copy all three values now and store them in your secret manager:
- Client ID
- Client secret
- API URL (also called the base URL — it varies by cloud region)
You will paste these into Britive in the next guide.
Upload the elevation scripts
Go to Host setup and management → Response scripts and files and upload one script per action, per platform you support.
| Platform | Grant | Revoke | Upload as |
|---|---|---|---|
| Windows 10 / 11 | windows/elevate.ps1 | windows/de-elevate.ps1 | PowerShell |
| macOS | macos/elevate.sh | macos/de-elevate.sh | Bash |
The upload name is the name Britive calls. Whatever you name a script here must match the Grant or Revoke permission configured on the Britive EPM profile exactly. Pick a convention now and keep it — for example britive-elevate-windows and britive-deelevate-windows.
Confirm a Response policy covers your target hosts
In Endpoint security → Response policies, verify that the policy assigned to the host group containing your workstations has Real Time Response enabled along with its admin-level commands.
runscript is an RTR Admin command, so a policy that stops at Active Responder will not run these scripts.
Test a script from RTR directly
Prove the script works before Britive is in the picture. Open an RTR session against a test workstation and run the grant script by the name you uploaded it under:
runscript -CloudFile="britive-elevate-windows" -CommandLine="-Username jdoe"Then revoke it again:
runscript -CloudFile="britive-deelevate-windows" -CommandLine="-Username jdoe"Read the last line of the returned output. It carries the script’s own verdict — the RTR command reports success either way. See Reading the Result.
What the Scripts Do
Both platforms follow the same shape: resolve the account, change the group, verify the change took, notify the user, then report the outcome on stdout. The verification step matters — a group change that silently failed would otherwise look like a successful elevation.
Full script: EPM/CrowdStrike/windows/elevate.ps1 · de-elevate.ps1
The account is resolved to a SID first, then added by SID so the membership check is not fooled by a renamed or duplicated account name. Re-running on an already-elevated account is a no-op rather than an error:
try {
$isMember = Get-LocalGroupMember -Group "Administrators" -ErrorAction Stop |
Where-Object { $_.SID.Value -eq $accountSid }
if ($isMember) {
Write-Output "User '$qualified' is already a local Administrator."
}
else {
Add-LocalGroupMember -Group "Administrators" -Member $qualified -ErrorAction Stop
Write-Output "SUCCESS: Added '$qualified' to local Administrators."
}
}
catch {
Exit-BritiveFail -Code 'GROUP_ADD_FAILED' -Message "Failed to add '$qualified' to local Administrators. $_"
}The script then locates the user’s desktop from the SID and writes the elevation launcher there. That step fails if the user has never signed in on the machine, because no user profile exists to write to.
Every script takes a single -Username parameter. RTR is non-interactive and cannot prompt, so a missing parameter is reported as MISSING_PARAM rather than a prompt.
Reading the Result
The RTR exit code tells you nothing. A runscript invocation reports whether Falcon delivered and ran the command, not what the script concluded. The script’s own exit code is not carried in the admin-command response at all. A script that failed to elevate still comes back as a successful RTR command.
Because of that, the outcome travels in stdout. Every script ends by writing one line:
BRITIVE_STATUS {"status":"success","action":"elevate","code":"OK","user":"CONTOSO\\jdoe","host":"WKS-01","message":"...","warnings":["notify_no_session"]}| Field | Meaning |
|---|---|
status | success or error. The only field to branch on |
action | elevate or de-elevate |
code | Machine-readable reason — see below |
user | The account as the script resolved it, qualified (DOMAIN\user) on Windows |
host | The machine the script ran on |
message | Human-readable detail, truncated to 300 characters |
warnings | Non-fatal problems. Never affects status |
How to read it, in order:
- Take the last line matching
^BRITIVE_STATUS, strip the prefix, parse the rest as JSON. - If there is no such line, treat the run as an error. A missing marker means the script was killed, timed out, or its output was truncated — never that it succeeded.
- Branch on
status. Usecodefor specific handling; never parsemessage.
Rule 2 holds because the marker is written on every path, including unhandled failures — the Bash scripts arm an EXIT trap with a pessimistic default before doing any work, and the PowerShell scripts install a script-scope trap alongside the same default:
BRITIVE_STATUS="error"
BRITIVE_CODE="UNEXPECTED"
BRITIVE_MESSAGE="Script terminated before reaching an outcome."
...
trap emit_status EXITResult codes
code | status | Meaning |
|---|---|---|
OK | success | The group change was applied and verified |
NOT_MEMBER | success | De-elevate only. The account already held no admin rights; verified |
MISSING_PARAM | error | No -Username supplied |
NOT_PRIVILEGED | error | macOS only. Not running as root |
USER_NOT_FOUND | error | Elevate only. The account does not exist on the host |
RESOLVE_FAILED | error | Windows only. The name would not resolve to a SID |
GROUP_ADD_FAILED | error | The membership change was rejected |
GROUP_REMOVE_FAILED | error | De-elevate only. The removal was rejected |
VERIFY_FAILED | error | Membership could not be confirmed after the change |
NO_USER_PROFILE | error | Windows elevate only. No desktop folder — the user has never signed in |
DESKTOP_WRITE_FAILED | error | Windows elevate only. The launcher files could not be written |
UNEXPECTED | error | An unhandled error. message carries the exception text |
Two error codes leave the machine elevated. NO_USER_PROFILE and DESKTOP_WRITE_FAILED are raised by elevate.ps1 after the account has already been added to Administrators. The script does not roll that back. Treat either as a failed checkout and run the de-elevate script to clean up, or the user keeps standing admin rights.
Warnings
warnings records what degraded without changing the outcome — the privilege change is the deliverable; the notification and cleanup are not.
notify_no_session, notify_failed, notify_dialog_failed, notify_toast_failed, session_lookup_failed, profile_lookup_failed, verify_failed_soft, process_terminate_partial, file_delete_partial, desktop_not_found, user_not_found.
Human-readable prefixes
The chatty output above the marker uses consistent prefixes — SUCCESS:, VERIFIED:, WARNING:, ERROR: — which are useful when reading a run by hand. Do not parse them. They are for people; BRITIVE_STATUS is for machines.
Verify
Confirm the script ran
RTR returns the script’s output. Read the last line:
BRITIVE_STATUS {"status":"success","action":"elevate","code":"OK",...}"status":"success" with "code":"OK" means the group change was applied and verified. Anything else — including no marker at all — means it was not. Do not judge the run by whether the RTR command itself succeeded.
Confirm the membership on the endpoint
On Windows:
net localgroup AdministratorsOn macOS:
dseditgroup -o checkmember -m jdoe adminConfirm revocation
Run the revoke script and check the same command again. The account should be gone. On Windows the desktop launcher files should have been deleted too.
Troubleshoot
| Symptom | Likely cause | Fix |
|---|---|---|
| No option to upload a script | Your Falcon user lacks the RTR Admin role | Add Real Time Response Admin to your own user, not just the API client |
runscript is rejected, or the command never runs on the host | The Response policy for that host group does not include RTR admin-level commands | In Endpoint security → Response policies, enable Real Time Response and its admin-level commands for the policy covering those workstations |
No BRITIVE_STATUS line in the output | The script was killed, timed out, or output was truncated | Treat as a failure. Re-run and check the RTR session timeout |
MISSING_PARAM | The script was invoked without -CommandLine | Pass -CommandLine="-Username <account>" |
RESOLVE_FAILED (Windows) | The name will not resolve to a SID — commonly a UPN | Use the sAMAccountName, or DOMAIN\user. See Account Mapping |
USER_NOT_FOUND (macOS) | The account does not exist on the host — commonly a UPN | Use the local short name |
NOT_PRIVILEGED (macOS) | Script did not run as root | RTR runs as root by default — check for a custom execution context |
GROUP_ADD_FAILED / GROUP_REMOVE_FAILED | The membership change was rejected by the OS | Check local policy or endpoint protection blocking group edits |
VERIFY_FAILED | The change appeared to apply but could not be confirmed | Check the group directly on the host before retrying |
NO_USER_PROFILE (Windows) | The user has never signed in to that machine | Have them sign in once, then retry. Run de-elevate first — the account is already elevated |
DESKTOP_WRITE_FAILED (Windows) | The launcher files could not be written | Run de-elevate first — the account is already elevated. Then check desktop permissions |
status: success but the user sees nothing | warnings contains notify_no_session | Expected. The privilege change applied; only the notification was skipped |
| RTR unavailable entirely | Licence tier does not include RTR | RTR needs Falcon Insight or Falcon Enterprise |