Guide. Access review. Sharing links.
How to find files shared with anyone who has the link
Find open links in SharePoint, OneDrive and Google Drive, say how far back each search reaches, and keep the owner’s decision for every link.
Co-founder and CEO · Updated November 8, 2026

On this page
Two views of links, and what each can claim
Applies to SharePoint Online and OneDrive for Business in Microsoft 365, and to Google Drive in Google Workspace. The commands come from vendor documentation opened on November 8, 2026. Sylox has not yet run them.
No single report lists every anonymous link. Activity views list links created or used in a window. Snapshot views and current-state searches list links that exist today. Report each finding with the view that found it and the window it covers.
The Microsoft steps need a SharePoint administrator, plus a role that can run Search-UnifiedAuditLog for the audit search. The Google steps need a super administrator or a service account with domain-wide delegation. Allow half a day for a first pass over one tenant.
- Read the tenant sharing settings and export them
- Run the SharePoint reports and the audit search
- Search Google Drive for both visibility terms
- Send each owner their own links for a decision
- Re-run every search the same way and keep both outputs
Read what the tenant allows before you search
In the SharePoint admin center, open Policies, then Sharing. Anyone links can exist only where the sharing level is Anyone. OneDrive can be set stricter than SharePoint, never looser. Microsoft notes that with these links you can’t track who has access to the items or who accessed them, which is why oversharing reviews start here.
At the Anyone level you can require links to expire and limit them to view. The Set-SPOTenant parameters are RequireAnonymousLinksExpireInDays, FileAnonymousLinkType and FolderAnonymousLinkType. Get-SPOTenant reads the current values, so export them with the date before you change anything.
In the Google Admin console, open Apps, then Google Workspace, then Drive and Docs, then Sharing settings. Record the state of the setting that lets users make files visible to anyone with the link, for each organizational unit. Closed-ticket evidence for any change follows the remediation evidence guide.
SharePoint and OneDrive: the governance reports
Open Reports, then Data access governance, in the SharePoint admin center. The sharing links report is an activity report: it lists the sites where users created the most new links in the last four weeks. Anyone, organization and specific-people links are counted separately.
Run the site permissions report for your organization first. It is a snapshot across SharePoint and OneDrive sites, and it gives the baseline that the four-week activity reports are read against. Microsoft suggests snapshots quarterly and activity reports monthly.
On licensing, Microsoft’s prerequisites page lists SharePoint Advanced Management as available with at least one Microsoft Copilot license in the tenant, or with the Plan 1 add-on. Microsoft 365 E5 gets the reports without snapshots. With none of these, run Start-SPOAuditDataCollectionForActivityInsights first: the report then holds only data from the day collection began, kept four weeks.
The PowerShell route is Start-SPODataAccessGovernanceInsight, with the report entity SharingLinksAnyone and the report type RecentActivity, then Export-SPODataAccessGovernanceInsight for the CSV. It needs the Microsoft.Online.SharePoint.PowerShell module at version 16.0.25409 or later.
Search the audit log past 100 rows
Run it in Exchange Online PowerShell as an account allowed to run Search-UnifiedAuditLog. The cmdlet returns 100 records unless you page it, and a session stops at 50,000.
# Read-only. Anyone-link events for 30 days, paged with one SessionId.
Connect-ExchangeOnline -UserPrincipalName auditor@example.com
$start = [datetime]'2026-10-09'
$end = [datetime]'2026-11-08'
$session = 'anyone-links-20261108'
$rows = @()
do {
$page = Search-UnifiedAuditLog -StartDate $start -EndDate $end `
-Operations AnonymousLinkCreated,AnonymousLinkUsed `
-ResultSize 5000 -SessionId $session -SessionCommand ReturnLargeSet
$rows += $page
} while ($page -and $page.Count -gt 0)
# ReturnLargeSet is unsorted, so sort and drop repeated records by Identity.
$events = $rows | Sort-Object Identity -Unique | ForEach-Object {
$d = $_.AuditData | ConvertFrom-Json
[pscustomobject]@{
Date = $_.CreationDate; Operation = $_.Operations
User = $d.UserId; Object = $d.ObjectId; ClientIp = $d.ClientIP
}
}
"Records returned: $($rows.Count); after removing repeats: $($events.Count)"
$events | Sort-Object Date | Export-Csv anyone-link-events-20261108.csv -NoTypeInformation
# Count at 50,000? Split the dates and run each part with its own SessionId.Read the audit output, and prove it is complete
AnonymousLinkCreated marks a new Anyone link. AnonymousLinkUsed marks someone opening one, and Microsoft says the opener’s identity might be unknown, though details such as the IP address are recorded. AnonymousLinkUpdated and AnonymousLinkRemoved complete the history of a link.
The search reaches back as far as audit retention. Audit (Standard) keeps records for one hundred eighty days, for events generated on or after October 17, 2023. Users with an E5-level license keep SharePoint and OneDrive records for one year by default. Records of guests and non-E5 users stay at one hundred eighty days.
To prove the export is complete, compare the record count with the count in the Purview audit search for the same dates and operations. A gap means the session limit cut the window. Microsoft itself recommends the Management Activity API for scripted, regular downloads.
Five links, five decisions
Findings from one tenant, merged from the reports and the audit export. Each decision belongs to the file owner, not to the administrator who ran the search.
| Identity | Role or group | Object | Privilege | Last used | Decision |
|---|---|---|---|---|---|
| Anyone with the link | Anonymous edit link, no expiry | HR > Payroll > salaries_2026.xlsx | Edit | AnonymousLinkUsed, November 2, 2026 | Remove today; check the AnonymousLinkUsed events for unknown IP addresses |
| Anyone with the link | Anonymous view link, no expiry | Projects > Atlas > customers_export.csv | View | No use in six months | Remove; share with the named contacts at example.com instead |
| Anyone with the link | Anonymous view link, expires January 31, 2027 | Marketing > press_kit.zip | View | AnonymousLinkUsed, November 5, 2026 | Keep: public by design, owner and expiry recorded |
| Anyone with the link | Anonymous view link, expires March 1, 2027 | Finance > board_pack_q3.pdf | View | Not measured | Not measured: the link predates the audit window; owner to decide |
| People in your organization | Organization link | Sales > pipeline_q4.xlsx | View | November 7, 2026 | Excluded from this review: not an Anyone link; it goes to the oversharing review |
Search Google Drive for both link states
Google’s Drive API has two visibility values that match an open link, anyoneWithLink and anyoneCanFind, so search for both. A full sweep repeats the call for each user.
# Read-only. Needs jq and an OAuth access token in $TOKEN, scope drive.metadata.readonly,
# obtained for one user (a service account with domain-wide delegation can impersonate each user).
Q="(visibility = 'anyoneWithLink' or visibility = 'anyoneCanFind') and trashed = false"
PAGE=''
while :; do
RESP=$(curl -s -G 'https://www.googleapis.com/drive/v3/files' \
-H "Authorization: Bearer $TOKEN" \
--data-urlencode "q=$Q" \
--data-urlencode 'pageSize=1000' \
--data-urlencode 'fields=nextPageToken,incompleteSearch,files(id,name,webViewLink,modifiedTime,owners(emailAddress))' \
${PAGE:+--data-urlencode "pageToken=$PAGE"})
echo "$RESP" | jq -r '.files[] | [.id, .name, .owners[0].emailAddress, .modifiedTime] | @tsv'
echo "$RESP" | jq -r '"incompleteSearch: " + (.incompleteSearch|tostring)' >&2
PAGE=$(echo "$RESP" | jq -r '.nextPageToken // empty')
[ -z "$PAGE" ] && break
done > drive-open-links-20261108.tsv
wc -l drive-open-links-20261108.tsv # compare with the Drive log events count for the same userDrive log events cover six months, the search covers today
In the Admin console, open Reporting, then Audit and investigation, then Drive log events, and add a condition on Visibility. This shows visibility changes in the log. The Reports API looks back one hundred eighty days at most, so links set earlier show only in the API search.
The API search reads today’s settings and nothing about their history. It returns files the calling user can see, and files.list can report incompleteSearch when some results were missed. Treat any user whose run printed true as not measured.
The security investigation tool, in the editions that include it, can act on search results. Any bulk action is a change, so raise a change record first and read Google’s page on the actions available for Drive.
Send each owner their links and set a deadline
Give every owner only their own links, with the file name, the link type, the expiry and the last use. The owner records one decision per link: remove it, switch it to named people, add an expiry, or keep it with a reason and an end date.
No one approves their own access. A second person signs the decisions about files that the searching administrator owns. Our recommendation is a removal deadline of five working days from the decision, recorded beside both dates.
In SharePoint, a site access review sends owners of overshared sites a review request from a governance report. It covers SharePoint sites and doesn’t reach OneDrive accounts. Removing the links happens in the source, against a change record.
What this method misses
The audit search shows links created or used inside the retention window and nothing older. The sharing links report covers SharePoint sites, and OneDrive reaches you through the snapshot report or PowerShell.
None of the views shows who opened a link in a way you can name. Anyone links are unauthenticated. A copy downloaded before a link was removed stays with the person who downloaded it. Outlook attachments and Teams chat files sit outside both the SharePoint reports and the Drive search.
Shared drives need their own run. The search above sees the files the calling user can reach, so a drive nobody was impersonated on is not measured. Write each such drive in your record as not measured, with its owner.
IRIS flags files open to anyone with the link in the sources you connect, and reads those files for sensitive data. Capabilities vary by edition.
Files open to anyone with the link: IRIS produces part of this, in connected SharePoint, OneDrive and Google Drive sources.
Sensitive data inside the open files: IRIS produces part of this, in the sources you connect.
Who accessed sensitive data in those files, and when: IRIS produces part of this, where the source keeps an audit log.
Removing or narrowing the link: Not produced by IRIS.
A dated re-scan after your team changes the sharing: IRIS produces this.
Explore access mappingRe-run the searches, then review the next risk
After the owners’ changes, run the audit search, the Drive search and the governance reports with the same dates and filters. File the two outputs together. The review passes when every link removed is absent from the second run and every link kept has an owner and a date.
A new link created between the two runs is a finding for the next cycle. The next step is the access an assistant inherits from these links: see the oversharing review before you switch on an AI assistant.
Official sources
- Search-UnifiedAuditLog: ResultSize, SessionId and SessionCommand, Microsoft Learn. Opened November 8, 2026.
- Audit log activities: AnonymousLinkCreated and AnonymousLinkUsed, Microsoft Learn. Opened November 8, 2026.
- Audit (Standard) and its retention, Microsoft Learn. Opened November 8, 2026.
- Data access governance reports for SharePoint and OneDrive, Microsoft Learn. Opened November 8, 2026.
- Data access governance reports with PowerShell, Microsoft Learn. Opened November 8, 2026.
- SharePoint Advanced Management prerequisites, Microsoft Learn. Opened November 8, 2026.
- External sharing settings for SharePoint and OneDrive, Microsoft Learn. Opened November 8, 2026.
- Drive API search terms: visibility, Google for Developers. Opened November 8, 2026.
- Drive log events, in the Admin console, Google Workspace Admin Help. Opened November 8, 2026.
- Reports API activities.list and its look-back limit, Google for Developers. Opened November 8, 2026.
Start with a free assessment of one database you choose.
Get a free assessmentAnyone link questions
That is the cmdlet’s default page. Set ResultSize to 5,000 and repeat the call with the same SessionId and the ReturnLargeSet value until it returns nothing. A session ends at 50,000 records, so split longer windows.
No. Files discoverable by anyone on the web carry the value anyoneCanFind. Search for both, as the query above does, or the public files stay in no list.
No, not always. They come with SharePoint Advanced Management, available through one Copilot license or the Plan 1 add-on. Without it, switch on data collection and accept four weeks of history from that day.
No. IRIS flags the link and records the finding. Your team changes the sharing in the source, and a re-scan records the new condition.
Protect your brand. Start with your data.
Bring one SharePoint site or shared drive. We’ll show which files IRIS flags as open to anyone with the link, read-only.


