Microsoft provides built-in tools to report on shared links and file locations: Sharing Links Report : In SharePoint, go to Settings (Cog icon) Site Usage Shared with external users Run report
An "Index of Files" link usually refers to a directory listing index of files link
When used intentionally, directory indexing is not a security flaw but a useful feature: Microsoft provides built-in tools to report on shared