Skip to content

Conversation

@chrootsu
Copy link
Contributor

This is necessary to copy a flag XATTR_PAX.

@maxrimue
Copy link
Contributor

Sorry, could you provide some more information about what this flag really changes?

@chrootsu
Copy link
Contributor Author

The flag disables mprotect(). This PR corrects an omission in #228

@maxrimue
Copy link
Contributor

I just tried using n with this patch on OS X, and it throws this error for me:

n max$ ./bin/n 4.0.0

     install : node-v4.0.0
       mkdir : /usr/local/n/versions/node/4.0.0
       fetch : https://nodejs.org/dist/v4.0.0/node-v4.0.0-darwin-x64.tar.gz
######################################################################## 100,0%
cp: illegal option -- -
usage: cp [-R [-H | -L | -P]] [-fi | -n] [-apvX] source_file target_file
       cp [-R [-H | -L | -P]] [-fi | -n] [-apvX] source_file ... target_directory
cp: illegal option -- -
usage: cp [-R [-H | -L | -P]] [-fi | -n] [-apvX] source_file target_file
       cp [-R [-H | -L | -P]] [-fi | -n] [-apvX] source_file ... target_directory
cp: illegal option -- -
usage: cp [-R [-H | -L | -P]] [-fi | -n] [-apvX] source_file target_file
       cp [-R [-H | -L | -P]] [-fi | -n] [-apvX] source_file ... target_directory
cp: illegal option -- -
usage: cp [-R [-H | -L | -P]] [-fi | -n] [-apvX] source_file target_file
       cp [-R [-H | -L | -P]] [-fi | -n] [-apvX] source_file ... target_directory
   installed : v4.0.0

And since this error doesn't occur without this change, there must be something wrong with the patch. Ideas?

@chrootsu
Copy link
Contributor Author

I have no experience with OS X, but it looks like cp has no option --prevent. I'll try to fix it another way.

@chrootsu chrootsu force-pushed the copy-xattr-when-activate branch from c63853e to 4ba566c Compare September 16, 2015 19:58
@chrootsu chrootsu changed the title Added the copying of extended attributes during an activation. Added the disabling PaX's mprotect() during an activation. Sep 16, 2015
@chrootsu
Copy link
Contributor Author

@maxrimue Could you check again, please? Now it should work correctly.

@chrootsu chrootsu force-pushed the copy-xattr-when-activate branch from 4ba566c to cefebb2 Compare September 16, 2015 20:02
@maxrimue
Copy link
Contributor

Yep, now it works, thanks!

maxrimue added a commit that referenced this pull request Sep 16, 2015
Added the disabling PaX's mprotect() during an activation.
@maxrimue maxrimue merged commit 1388dd0 into tj:master Sep 16, 2015
@chrootsu
Copy link
Contributor Author

Thank you! ^_^

@maxrimue
Copy link
Contributor

No problem 👍

@chrootsu chrootsu deleted the copy-xattr-when-activate branch October 14, 2015 01:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants