Separate names with a comma.
Discussion in 'iOS Programming' started by raziiq, Aug 6, 2009.
Is there anyway i can change the permissions of the iPhone system folders through code?
If you mean folders outside the sandbox, of course not. If you mean something inside the sandbox, you can but why would you want to?
i mean folders outside the sandbox. I need to copy some files to it. May be to the /tmp folder.
But the main question is how to change the permissions, what should be the syntax?
I think you would be able to for Jailbroken iPhones but no way for regular iPhone. Are you trying to implement the iPhone virus discussed in the other thread
Come on man, its not about virus or something. Ya i m developing for Jailbroken iPhone
Then you probably need to go find some forums dealing with jailbroken phones then. That's not really discussed here. Sorry.
Well, it's the same code inside the sandbox or out.
Look at the docs for NSFileManager. You need to set the NSFilePosixPermissions.
man 2 chmod