fix photo permissions on encrypted posts