Examples
This page contains detailed usage examples that include sample input CSVs, command line arguments, and what to expect once the remediation is running.
Yahoo Mail with Modern Authentication
Section titled “Yahoo Mail with Modern Authentication”Two Yahoo mailboxes accessed over IMAP using modern authentication (OAuth).
What You Need
- An app registered in the Yahoo developer portal with read/write access to Mail. Its client ID goes on the command line, and its client secret is prompted for.
- Credentials for the target Yahoo accounts. Since the remediation is using modern authentication, an App Password is not needed.
Input CSV (fluxcap.csv)
IMAP uses the folder name to address a message. Therefore, each CSV line must contain folder information.
ServiceId,Folder,TargetEmailCommand
.\Obliterator.exe start -p outatime.obproj ` --provider Imap --auth-mode Interactive --imap-oauth-provider yahoo ` --client-id <client-id> -i fluxcap.csvWorkflow
- Obliterator asks for the client secret.
- For each account in turn, it opens Yahoo’s consent page in the browser. Yahoo shows an authorization code on its own page, and you type it in when Obliterator asks.
- After both accounts are authenticated, the summary is shown and your confirmation is required to start remediation.
The server, export.imap.mail.yahoo.com, comes from the preset, so --imap-host is not needed.
Microsoft Personal Account with Modern Authentication
Section titled “Microsoft Personal Account with Modern Authentication”An Outlook.com mailbox, remediated through Microsoft Graph. The same applies to Hotmail, Live and MSN, and to a personal Microsoft account on any other domain.
What You Need
- An Azure app registration whose Supported account types is Any Entra ID Tenant + Personal Microsoft accounts. Organizational-only registrations refuse a personal account at the sign-in page.
- A Mobile and desktop applications redirect URI of
http://localhost, and the delegatedMail.ReadWritepermission (IMAP.AccessAsUser.Allwhen using IMAP). See App Registration. - Credentials to the target mailbox.
A personal account remediation via Graph API requires no tenant ID or client secret.
Input CSV (daisy.csv)
ServiceId,TargetEmailAQMkADAwATM0MDAAMi1kNjk4LTgwNzgtAAAD7xOB9gAAAA==,[email protected]AQMkADAwATM0MDAAMi1kNjk4LTgwNzgtAAAD7xOB9gAAAQ==,[email protected]AQMkADAwATM0MDAAMi1kNjk4LTgwNzgtAAAD7xOB9gAAAg==,[email protected]Command
.\Obliterator.exe start -p discovery.obproj ` --provider GraphMail --auth-mode Interactive --client-id <client-id> ` -i daisy.csvThe same mailbox over IMAP, for a CSV taken from an IMAP acquisition. Every row then needs a
Folder, and the server comes from the mspersonal preset.
.\Obliterator.exe start -p discovery.obproj ` --provider Imap --auth-mode Interactive --imap-oauth-provider mspersonal ` --client-id <client-id> -i daisy.csvWorkflow
The browser opens Microsoft’s sign-in page with the custodian’s email address prepopulated.
Obliterator checks the authenticated identity and refuses remediation if it does not match
the TargetEmail.
M365 Mail with App-only Authentication
Section titled “M365 Mail with App-only Authentication”Three mailboxes in an M365 tenant, remediated using App-only Authentication. This is a common choice for enterprise remediation scenarios where multiple custodians are targeted.
What You Need
- An Azure app registration in the custodians’ tenant with the application permission
Mail.ReadWrite, granted admin consent. - A client secret or a certificate for that registration.
- The tenant ID.
See App Registration.
Input CSV (crew-expendable.csv)
With App-only Authentication, TargetEmail can be any email address of the mailbox.
ServiceId,TargetEmailAAMkADk3ZTQ1NjE4LTc3YjMtNDI2Mi05MzdlAAA=,[email protected]AAMkADk3ZTQ1NjE4LTc3YjMtNDI2Mi05MzdlAAE=,[email protected]AAMkADk3ZTQ1NjE4LTc3YjMtNDI2Mi05MzdlAAI=,[email protected]AAMkADk3ZTQ1NjE4LTc3YjMtNDI2Mi05MzdlAAM=,[email protected]Command
The client secret is prompted for.
.\Obliterator.exe start -p order-937.obproj ` --provider GraphMail --auth-mode AppOnlySecret --client-id <client-id> ` --tenant-id <tenant-id> -i crew-expendable.csvThe certificate’s password is prompted for. The PFX certificate is stored in the remediation project.
.\Obliterator.exe start -p order-937.obproj ` --provider GraphMail --auth-mode AppOnlyCertificate --client-id <client-id> ` --tenant-id <tenant-id> --pfx-path mu-th-ur.pfx ` -i crew-expendable.csvThe same remediation in a sovereign cloud. --tenant-id is required.
.\Obliterator.exe start -p order-937.obproj ` --provider GraphMail --auth-mode AppOnlySecret --cloud GccHigh ` --client-id <client-id> --tenant-id <tenant-id> ` -i crew-expendable.csvWorkflow
Since App-only Authentication uses the same set of credentials for multiple mailboxes, identity check does not apply.
Google Workspace with Domain-Wide Delegation
Section titled “Google Workspace with Domain-Wide Delegation”Multiple accounts in a Google Workspace tenant remediated using domain-wide delegation of authority. As with M365 App-only Authentication, one set of credentials accesses all target accounts.
What You Need
- A Google service account with a JSON key, in a Google Cloud project with the Gmail API enabled.
- Domain-wide delegation granted to that service account in the Google Admin console, under
Security > Access and data control > API controls > Domain-wide delegation. Add its client ID
with the scope
https://mail.google.com/(enable Drive API and add thehttps://www.googleapis.com/auth/drivescope if targeting Google Drive files).
See App Registration.
Input CSV (swingline.csv)
ServiceId,TargetEmail18c3f1a2b4d5e6f7,[email protected]18c3f1a2b4d5e6f8,[email protected]18c3f1a2b4d5e6f9,[email protected]18c3f1a2b4d5e6fa,[email protected]18c3f1a2b4d5e6fb,[email protected]Command
.\Obliterator.exe start -p cover-sheets.obproj --provider Gmail --auth-mode Dwd ` --dwd-json initech-dwd.json -i swingline.csvFor a large remediation, Bulk deletes up to 1,000 messages per request. Gmail reports nothing
per message for a bulk request, so every deletion is verified afterwards.
.\Obliterator.exe start -p cover-sheets.obproj --provider Gmail --auth-mode Dwd ` --dwd-json initech-dwd.json --deletion-mode Bulk ` -i swingline.csvThe same Google service account can remediate Drive files. Enable the Drive API, add
https://www.googleapis.com/auth/drive to the delegation, and use a CSV of Drive file IDs.
.\Obliterator.exe start -p cover-sheets-drive.obproj ` --provider GoogleDrive --auth-mode Dwd --dwd-json initech-dwd.json ` -i swingline-files.csvWorkflow
The JSON key is stored in the remediation project.
Google Drive with Modern Authentication
Section titled “Google Drive with Modern Authentication”Files in two custodians’ Google Drives, remediated by authenticating interactively for each account. This can be a viable option when the target accounts are personal Google accounts or when a Google Workspace administrator does not allow the use of domain-wide delegation of authority.
What You Need
- A Google Cloud OAuth client of type Desktop app, in a project with the Google Drive API enabled and the consent screen in Testing. Its client ID is supplied as a command line argument and its client secret is prompted for. See App Registration.
- Credentials for the target accounts.
Input CSV (chamber19.csv)
ServiceId,TargetEmail1kR7vQm2XbT9pLw4ZcN8yHd3JfG6sAe0U,[email protected]1Qw8eRt5yUi2oPa7sDf4gHj9kLz3xCv6B,[email protected]1Mn5bVc8xZa2sDq7wEr4tYu9iOp3lKj6H,[email protected]Command
.\Obliterator.exe start -p black-forest.obproj ` --provider GoogleDrive --auth-mode Interactive --client-id <client-id> ` -i chamber19.csvWorkflow
- Obliterator asks for the client secret.
- For each account, the browser opens Google’s consent page for that target address for authentication.
- Obliterator confirms with Google Drive that the account that authenticated is the one the CSV names, and skips an account that does not match.
- The summary is shown and you confirm the permanent deletion.
Files are deleted permanently, bypassing Drive’s trash.
More Examples
Section titled “More Examples”Basic authentication against an IMAP server, with every message’s SHA-256 hash compared with
the one recorded during acquisition before the message is deleted. A message that does not match is left
in place. Each account’s password is prompted for unless it is supplied by the input CSV’s Password column.
bypass.csv:
ServiceId,Folder,Mime Hash [SHA256],TargetEmailCRDYQIAAE9h,INBOX,92D7B8C6689FC32DE6DF7869BCC246CFABF5C8331346B97BCFA61EB43A80EE68,[email protected]DhbJ2MAAD0r,INBOX/Bypass,5F31E15920D4B59BF8F4B54DE8BD8EAA713E0721A9E684E693A9D99B64736948,[email protected].\Obliterator.exe start -p mostly-harmless.obproj --provider Imap --auth-mode Basic ` --imap-host imap.megadodo.example --verify-hashes ` -i bypass.csvOne service account acting on every mailbox through Exchange impersonation. The service account’s password is prompted for.
.\Obliterator.exe start -p august-29.obproj ` --provider Ews --auth-mode Basic --ews-url https://mail.cyberdyne.example ` --use-impersonation --username svc-mdyson ` -i model-101.csvFiles in SharePoint document libraries remediated with App-only Authentication and a certificate. The
registration needs the application permission Sites.ReadWrite.All, granted admin consent.
Each row names its document library with a DriveId, which is the most efficient way to address a
file. A row can name a Site instead, and Obliterator then searches the site’s libraries
(see Input CSV).
ServiceId,TargetEmail,DriveId.\Obliterator.exe start -p tannhauser.obproj ` --provider SharePoint --auth-mode AppOnlyCertificate --client-id <client-id> ` --tenant-id <tenant-id> --pfx-path voight.pfx ` -i offworld.csvPick up where a remediation left off (e.g., after it was stopped with --retry-permanent-errors also attempts the items recorded as permanent
errors once more. Remaining settings are populated from the existing remediation project settings.
.\Obliterator.exe resume -p outatime.obproj --retry-permanent-errorsA scripted remediation with no one at the keyboard. --yes skips the confirmation, so only
authentication modes that need no browser sign-in and no prompt are suitable, and the Windows
user running it must already have accepted the EULA interactively. The exit code
tells a script whether items remain (1), the remediation was refused (2), or it failed
(70).
.\Obliterator.exe start -p cover-sheets.obproj --provider Gmail --auth-mode Dwd ` --dwd-json initech-dwd.json ` -i swingline.csv --yes