@nprofile1q... I still think it is a bug though, because I didn't get any error message when sharing the file within the web interface, and it allowed me to generate a link (both of us had emails on the same company domain).
If the org policy is configured such that you cannot share these files within the org either, then it should've given me an error message during the share operation.