When a supplier relationship ends, the contract stops but the access usually does not. Vendors accumulate accounts, API keys, OAuth grants, cross-account roles, VPN profiles and copies of your data over years, and very few of those are tied to the contract record that procurement closes. The result is a population of orphaned credentials with no owner and no reason to exist, which attackers find and use. This guide covers the exit itself: the triggers, the access inventory, the order of revocation and rotation, data return and deletion, the contract terms that make exit workable, and how to prove it was done. It is for TPRM leads, IAM and security operations teams, and service owners. For the full supplier life cycle, see the Third-Party Risk Management Guide.
Key takeaways
- Treat exit as a security change, not an admin task. Every vendor exit needs a named owner, an access inventory and a dated revocation record, just like a privileged leaver.
- Machine credentials are the hard part. Human vendor accounts usually sit in the identity provider; API keys, OAuth grants, service accounts and cross-account roles live in individual platforms and are what get missed.
- Disable first, delete later. Deactivation stops access while keeping evidence and a rollback path; deletion comes after a quiet period and any investigation.
- Rotate what the vendor knew, not just what it held. Shared secrets, webhook signing keys and credentials the vendor could read in your systems must change, even if the vendor's own accounts are removed.
- Get data deletion in writing. For personal data, GDPR Article 28(3)(g) requires deletion or return at the end of the service; ask for a dated confirmation that covers sub-processors and backups.
Why vendor exit is a security event
Incidents involving forgotten supplier access follow the same pattern: a credential was issued for a specific purpose, the purpose ended, and nobody owned its removal. In the Klue OAuth breach, a GitHub personal access token given to a third party for a limited pilot in 2022 was never revoked and was used in June 2026 to push malicious code into an integration service that held customers' Salesforce tokens. The pilot had ended years earlier; the token had not.
Exit is also the moment of weakest attention. Commercial teams have moved on, the vendor's staff may have left or been made redundant, and in a dispute the vendor has little reason to help. Planning the exit at onboarding is what makes it possible later.
Exit triggers and how they change the plan
| Trigger | Typical timeline | Security posture | What changes |
|---|---|---|---|
| Planned contract expiry or non-renewal | Weeks to months of notice | Cooperative | Run a phased exit with a transition period; agree data return format early |
| Replacement by a new supplier | Overlap period | Cooperative but competing | Both suppliers hold access during overlap; time-box and monitor the outgoing one |
| Termination for cause (breach, poor performance) | Days | Adversarial possible | Revoke access before or at notification; preserve logs first; involve legal |
| Supplier breach or compromise | Hours | Emergency | Run the incident playbook first, exit second. See the Third-Party Incident Response Playbook |
| Acquisition of the supplier | Variable | Uncertain | Reassess; new owner may move data or sub-processors; exit if the risk changes |
| Supplier insolvency or product end of life | Short and unpredictable | No counterparty | Assume no vendor help; rely on your own revocation and escrow or export rights |
| Project or pilot ends, contract continues | Often never recorded | Silent | The most missed case: access for one project must end even though the supplier relationship continues |
The last row matters most. Pilots, proofs of concept and one-off consulting engagements rarely produce a termination notice, so tie every vendor credential to a purpose and an expiry date at issue.
Who owns the exit
- Supplier relationship owner: accountable for starting the exit, confirming the end date and signing off completion.
- Procurement or vendor management: issues notices, tracks contractual exit obligations and closes the supplier register entry.
- IAM and platform teams: execute revocation in the identity provider, cloud accounts and SaaS consoles, and report what they removed.
- Security operations: preserves logs, monitors the quiet period and investigates any post-exit access attempt.
- Privacy and legal: instruct data return or deletion, review deletion evidence and handle disputes.
Record each step against the same exit ticket, so an auditor can see what was removed, by whom and when.
Build the access inventory
Before revoking anything, list every way the vendor can reach your environment and every place your data or secrets sit with the vendor. Sources include the identity provider, privileged access management, cloud IAM, SaaS admin consoles, OAuth consent logs, firewall and VPN configuration, secrets managers and the contract file.
| Access type | Where to find it | Exit action |
|---|---|---|
| Named vendor staff accounts and guest users | Identity provider, B2B guest lists, PAM | Disable, revoke sessions and refresh tokens, remove from groups. See the Entra ID Cross-Tenant Access and B2B Guest Governance Guide |
| Shared or generic vendor logins | Application local accounts, password vaults | Disable and rotate; these are often outside SSO and SCIM |
| Service accounts and integration users | SaaS admin consoles, directory, databases | Disable, then remove after quiet period. See the NHI Offboarding and Decommissioning Guide |
| API keys and personal access tokens | Each platform's key management page, secrets manager | Revoke; check for keys created by the vendor's accounts |
| OAuth grants and enterprise apps | Consent logs, enterprise applications, connected apps | Revoke grants and refresh tokens; deactivate the app. See the SaaS and OAuth App Governance Guide |
| Cloud cross-account roles | Role trust policies, IAM Access Analyzer external access findings | Revoke active sessions, then remove the trust. See the Cross-Account and Cross-Tenant Access Guide |
| Remote access tools, VPN profiles, jump hosts | PAM, VPN concentrator, remote support tooling | Remove profiles and agents; close vendor-specific firewall rules. See the Vendor Privileged Access Management Guide |
| SSH keys and certificates | authorized_keys files, SSH CA, internal PKI | Remove keys; revoke certificates issued to the vendor |
| Network allow lists and webhooks | Firewalls, WAF, API gateways, webhook settings | Remove vendor IP ranges; delete webhooks; rotate webhook signing secrets |
| Your secrets held by the vendor | Contract, integration docs, vendor configuration | Rotate every credential you gave the vendor for your systems |
| Your data held by the vendor and its sub-processors | Data processing agreement, sub-processor list, records of processing | Return or delete, with written confirmation |
Revocation and rotation sequence
Order matters. Removing a role before killing its sessions, or deleting an account before exporting its logs, loses either control or evidence.
- Freeze and preserve. Export sign-in and audit logs for every vendor identity for the retention period you will need. Snapshot configuration of integrations you are about to remove.
- Agree the cut-over time. For cooperative exits, set a date and time with the service owner and the vendor, and confirm a rollback contact. For termination for cause, revoke at or before notification.
- Disable human access. Disable vendor accounts in the identity provider, revoke sessions and refresh tokens, and remove MFA registrations the vendor controls.
- Kill live machine sessions. Changing an AWS role trust policy only controls future AssumeRole calls; to stop credentials already issued, use the role's Revoke active sessions action, which attaches the inline AWSRevokeOlderSessions deny based on aws:TokenIssueTime. Revoke OAuth refresh tokens rather than waiting for access tokens to expire.
- Disable integrations. In Microsoft Entra ID, deactivating an enterprise application blocks token issuance and sign-in while keeping its configuration, which is the safer first step; deletion is a soft delete held for 30 days before hard deletion.
- Rotate shared secrets. Rotate anything the vendor knew or could read: shared service passwords, database credentials in vendor-managed configuration, webhook signing keys and encryption keys the vendor handled. See the Secrets Rotation Runbook Template.
- Remove network paths. Delete vendor IP allow-list entries, site-to-site tunnels and remote support agents.
- Monitor the quiet period. Watch for any authentication attempt by vendor identities, source IPs or app IDs for 30 to 90 days. Any hit is either a missed dependency or an incident.
- Delete and close. After the quiet period, delete disabled identities, remove trust relationships permanently and update the supplier register and CMDB.
Rollback: if a business process breaks, re-enable the specific disabled object for a fixed period with a named owner, then migrate the dependency. Never roll back by reissuing a broad new credential to the vendor.
Data return and deletion
- The legal baseline for personal data: under GDPR and UK GDPR Article 28(3)(g), the processor must, at the controller's choice, delete or return all personal data at the end of the services and delete existing copies unless law requires storage. The ICO accepts that backups may not be deleted immediately if the data is put beyond use and deleted on the next deletion cycle.
- Sub-processors: Article 28(3)(d) requires the processor to impose equivalent obligations on sub-processors and leaves it liable for them. Ask for confirmation that deletion covers every sub-processor on the current list. See the Fourth-Party and Nth-Party Risk Guide.
- Return format first, deletion second: agree export format, integrity checks and a test restore before you instruct deletion. Once deleted, a bad export cannot be redone.
- Evidence: ask for a dated, signed statement naming systems, backup schedules, sub-processors and the sanitisation method used. Where you supplied physical media or devices, ask for a certificate of sanitisation. See the Media Sanitisation Guide.
- Keys you control: where data sat encrypted under customer-managed keys, revoking or destroying the key is a strong additional assurance that remaining copies are unreadable.
See the Data Retention and Secure Deletion Guide.
Contract terms that make exit workable
| Clause | What it gives you at exit |
|---|---|
| Inventory of access and credentials | A vendor obligation to list every account, key and integration it uses, kept current |
| Data return and deletion | Format, timeline, scope including backups and sub-processors, and written confirmation |
| Transition assistance | A defined period in which the vendor keeps operating and cooperates with migration |
| Termination rights | The right to exit for security breaches or material control failures, with notice periods |
| Audit and evidence | Article 28(3)(h) style rights to information needed to verify deletion |
| Post-termination confidentiality | Obligations on knowledge of your environment that outlive the contract |
| Escrow or export rights | Access to code or data if the vendor fails or the product ends |
For EU financial entities, DORA expects contracts for ICT services to address termination rights, notice periods, data access and return on insolvency or discontinuation, and exit strategies with transition periods, as its recitals 71 and 74 set out. See the DORA ICT Third-Party Risk and Register of Information Guide and the Third-Party Security Contract Clauses Template.
Decision guidance
- Disable or delete: disable at exit; delete after the quiet period and once no investigation or dispute needs the object. Delete immediately only where keeping the object is itself a risk, such as a still-valid static key.
- Revoke before or after notice: for cooperative exits, revoke at the agreed cut-over. For termination for cause, revoke first and notify second, after legal review.
- Rotate everything or targeted rotation: rotate everything the vendor could read where it had administrative access or where the exit follows an incident; targeted rotation of known shared secrets is acceptable for low-tier suppliers with narrow access.
- Small organisations: a single exit checklist owned by IT, with the identity provider and a shared spreadsheet of vendor credentials, covers most cases.
- Large organisations: link the procurement exit workflow to IGA so that a contract end date automatically raises access reviews and revocation tasks for every identity tagged to that supplier.
Detection and measurement
- Monitor: failed and successful sign-ins by disabled vendor identities, use of revoked OAuth client IDs, AssumeRole attempts against removed roles, and traffic from removed vendor IP ranges.
- Find orphans continuously: run IAM Access Analyzer or equivalent external access reports, OAuth app inventories and key age reports, and match every result to an active contract.
| Metric | What good looks like |
|---|---|
| Time from contract end to full revocation | Within five business days for all tiers; same day for termination for cause |
| Vendor credentials with an owner and expiry date | All of them |
| Post-exit authentication attempts by vendor identities | Zero after the first week; every hit investigated |
| Exits with written data deletion confirmation | All exits involving personal or confidential data |
| External access findings not mapped to an active supplier | Trending to zero |
Framework mapping
| Framework | Reference | Relevance |
|---|---|---|
| NIST CSF 2.0 | GV.SC-10 | Supply chain plans include provisions for activities after the conclusion of a partnership or service agreement |
| NIST CSF 2.0 | PR.AA-01, PR.AA-05 | Identities and credentials managed; access permissions reviewed and removed |
| NIST SP 800-53 Rev. 5 | PS-7, SA-9, AC-2 | External personnel security, external system services, account management |
| CIS Controls v8.1 | Safeguard 15.7 | Securely decommission service providers |
| ISO/IEC 27001:2022 Annex A | 5.19, 5.20, 5.22, 8.10 | Supplier relationships, supplier agreements, change management of supplier services, information deletion |
| GDPR and UK GDPR | Article 28(3)(d), (g), (h) | Sub-processors, deletion or return, information and audits |
Common failure patterns
- Exit not linked to identity: procurement closes the contract and nobody tells IAM, so every vendor credential survives. Klue's pilot token is the clearest example.
- Believing a credential is unused: after the 2023 Okta support breach, Cloudflare rotated thousands of credentials but missed one service token and three service accounts it believed were unused, including integration credentials for third-party tools, which an attacker then used. See the Cloudflare Thanksgiving breach.
- Removing the trust but not the sessions: editing a role trust policy or deleting a user while issued tokens remain valid.
- Forgetting reverse credentials: the vendor's accounts are removed but the credentials you gave the vendor for your systems are never rotated.
- Deleting before exporting: data or logs are deleted before the export is verified or an investigation is complete.
- Project access inside a live contract: consultants keep access after their engagement because the supplier relationship continues.
Practitioner checklist
- Tag every vendor identity and credential with supplier, purpose, owner and expiry at issue.
- Link contract end dates and project closures to automatic revocation tasks.
- Build the access inventory from IdP, PAM, cloud IAM, OAuth logs, network config and secrets managers before exit.
- Export logs and configuration before disabling anything.
- Revoke live sessions and refresh tokens, not just accounts and trust policies.
- Rotate every secret the vendor held or could read, including webhook signing keys.
- Obtain dated written confirmation of data return and deletion covering backups and sub-processors.
- Monitor vendor identities, client IDs and IP ranges for 30 to 90 days after exit.
- Delete disabled objects after the quiet period and update the supplier register.
Standards and references
- NIST: Cybersecurity Framework 2.0
- NIST: SP 800-161 Rev. 1, Cybersecurity Supply Chain Risk Management Practices for Systems and Organizations
- NIST: SP 800-53 Rev. 5
- ICO: What needs to be included in the contract
- EUR-Lex: Regulation (EU) 2022/2554 on digital operational resilience (DORA)
- AWS: Revoke IAM role temporary security credentials
- Microsoft Learn: Delete an enterprise application
- CIS: Control 15 Service Provider Management
Related NHI Mgmt Group resources: Third-Party Risk Management Guide · Third-Party Access Guide · OWASP NHI Top 10 NHI1 Improper Offboarding Guide · Employee Offboarding Security Guide