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

Stop use of intermediate shell and sandbox commands. #37

Open
alloy opened this issue Sep 30, 2014 · 1 comment
Open

Stop use of intermediate shell and sandbox commands. #37

alloy opened this issue Sep 30, 2014 · 1 comment

Comments

@alloy
Copy link
Member

alloy commented Sep 30, 2014

(iirc, the reason we use an intermediate shell has to do with Ruby 1.8 and 1.9/2.x differences)

When we drop Ruby 1.8.7 support, we should:

  • Make the download commands use arrays of commands instead of string commands, this way we can spawn subprocesses without the need for a shell. This ensures we’ll no longer have the chance for breakage related to spaces in paths and/or other characters that might need to be spaced before using in a shell.
  • Use OS X sandboxing to limit access of the invoked command to just network access and write access to the destination dir. This ensures that a command (coming from a podspec's source attribute) can no longer inject malicious commands that invokes commands other than the download command in question (e.g. git) and cannot make FS changes outside of the destination dir where it is expected to make changes.
@segiddins
Copy link
Member

This was 1/2 done in #43. The sandboxing bit still hasn't been addressed, though.

@segiddins segiddins reopened this Mar 29, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants