Refine usage of secure_sharing