Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update permissions of temporary file because the native imessage agent on iOS doesn't have root permissions #44

Closed
wants to merge 2 commits into from

Conversation

CarlAmbroselli
Copy link
Contributor

Sorry for filing #43, this turned out to be a red herring. After the PR was closed I had no other way of getting this build than setting up the local iMessage go build environment myself, so I went ahead and did that last night.

When testing out, I learned that the deletion of the file isn't the issue, but rather that on iOS the IMFileTransferCenter daemon doesn't run as root user (obviously) and hence isn't able to read the temp folder with 700 permissions created as root.

After changing both the temp folder permissions, as well as the file permissions sending images from matrix via Barcelona to iMessage works like a charm.

@CarlAmbroselli
Copy link
Contributor Author

@EricRabil / @tulir would one of you review this? Have this running since a few days now and haven't found any issues or crashes around attachments yet

Copy link
Member

@tulir tulir left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It should probably only make them world-readable on iOS

@CarlAmbroselli
Copy link
Contributor Author

@tulir updated the PR to have different permissions depending on if it's built for mac or iOS

@tulir tulir closed this in fbb1dbb Mar 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants