write plugin uploads with the correct permissions