writing an archive that contains encrypted files - libarchive

I've some files that are encrypted with nettle.
when I read the archive, they're all messed up... so is there's a preferred filter/format in order to keep those files straight?
best regards,
nicolas

problem solved...
I was not reading files to put in archive in binary mode.
what a great library :)
++

Related

How to uncompress .7z files in elixir/erlang

I am working on a problem which requires my system to uncompress .7z files in elixir/erlang.
Is there any such library that can uncompress .7z file in erlang or elixir? Or any method to do the same?
TIA :)
I guess that the best and simplest way for doing it is by running the right system command to uncompress the file.
You can do this using os:cmd/1:
In case you just want to uncompress to the working directory, just run this command:
os:cmd("7za x File.7z").
For more information about how to use 7z in command line see this or this.
Note: You just need to make sure you have the right 7z utility according to your OS.
You might also want to check out this Erlang module as well. http://erlang.org/doc/man/zip.html

Opening up an .ipa file - Piracy

How easy is it to open up an app submitted to Apple's store?
I'm going to submit a new app to the store soon, and want to protect the app file from being opened up to the source-code. So for instance, if I were to download my own app, how easy would it be to pull out all the .h and .m files and recreate it in Xcode?
Does Apple encrypt it somehow?
What steps can I take to mitigate the code being viewed?
EDIT: Allow me to rephrase the question a little better - can I take decompiled code and make it human-readable?
An IPA is just a zip. But you don't even need to access the IPA.
Just get iExplorer and access all available assets of your installed apps from your Mac.
The m files however build a compiled binary and can not be read (if you consider de-compiled code as not readable, as I do)
Adding on the answer, it is possible to decompile the binary, but the only thing that would be directly removable from the binary itself would be the headers (or to my knowledge of what I've seen). Then the application would be reverse engineered from there. That would probably be the only thing I'd be worried about when it comes to people stealing my code.

Command line tool to analyze a .app or .ipa file

In a script I'm writing, I want a way to be able to analyze a .ipa or .app file to determine some of its internals, such as which SDK it was built with. Is there a command line tool that allows you to do this? If so, what other information can you get from it?
Have a look at this: https://github.com/apperian/iOS-checkIPA (it's a tool named iOS IPA Validator, originally by G. Gold, maintained by James Seibel)
It helped me.
This also looks interested: https://github.com/sjmulder/ipa

How can I configue Gerrit to read iOS .strings files

I would like to examine differences in the iOS .strings files using Gerrit, but it doesn't seem to be able to handle their UTF-16 format. Does anyone have a solution for this? Or a workaround?
Although I haven't needed to configure .strings files before, I think the solution is to set the mime-type to safe. See http://gerrit-documentation.googlecode.com/svn/Documentation/2.6/config-gerrit.html#_a_id_mimetype_a_section_mimetype.

Access apps with AppleScript

Is there anyway to programmatically get a list of iOS apps from iTunes?
AppleScript does not seem able to do this.
The only way I can think of is looking in the 'iTunes Media/Mobile Applications' folder. But this way a lose all metadata.
Any suggestions to get list of iOS apps including the metadata?
Thanks
I now actually went with the solution to scan the 'Mobile Applications' folder.
In order to get the metadata I had to do the following:
the *.ipa are simply archives
unzip/extract the 'iTunesMetadata.plist' inside
parse the plist
voila you got all metadata
This whole process is actually pretty straightforward in python as your already have both zipfile and plistlib.
One thing to lookout for though is that plistlib in python can not handle the new binary plist files. So you first have to convert them to their corresponding xml format. (only some *.ipa seem to be in binary form).
This can be done quite easily with the following line of code:
os.system("/usr/bin/plutil -convert xml1 %s" % file_name )
Now the only thing I still have to figure out is how to get the currently installed apps on the device...

Resources