Information
Links may be used to provide access to information for a short period of time. Without expiration, however, access is indefinite. By setting expiration timers for links, administrators can prevent unintended sustained access to the link.
Solution
1. Sign in to the SharePoint admin center.
2. Select Policies \> Sharing.
3. Scroll to the section Choose expiration and permissions options for Anyone links.
4. Select the checkbox These links must expire within this many days.
5. Enter 30 days or less.
6. Select Save.