{ "info": { "author": "Dmitry Rodionov", "author_email": "i.am.rodionovd@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 3 - Alpha", "License :: OSI Approved :: MIT License" ], "description": "machobot \n======== \n\n.. image:: https://travis-ci.org/rodionovd/machobot.svg?branch=master\n :target: https://travis-ci.org/rodionovd/machobot\n.. image:: https://codeclimate.com/github/rodionovd/machobot/badges/gpa.svg\n :target: https://codeclimate.com/github/rodionovd/machobot\n :alt: Code Climate\n\nA Python toolbox for Mach-O files analysis. Heavily relies on\n``macholib``. \n \nInstallation \n------------ \n \nFor usage\n'''''''''\n\n::\n\n\t$ [sudo] pip install machobot\n\nFor development\n'''''''''''''''\n\n::\n\n\t$ pip install nose macholib\n\t$ git clone https://github.com/rodionovd/machobot.git machobot\n\t$ cd ./machobot\n\t$ nosetests # run the test suite\n\nUsage\n-----\n\n- As a command-line util:\n\n\t.. code:: bash\n\n\t $ inject_dylib ./target \"@rpath/mylib.dylib\"\n\n- As a Python module:\n\n\t.. code:: python\n\n\t import machobot\n\n\tExample usage:\n\n\t.. code:: python\n\n\t import machobot.dylib as dylib\n\n\t dylib.insert_load_command(\"output.a\", \"@executable_path/../../libk.dylib\")\n\t \nModules\n-------\n\ndylib\n'''''''''\n\n\t.. code:: python\n\n\t insert_load_command (target_path, library_install_name)\n\nInserts a new ``LC_LOAD_DYLIB`` load command into the target Mach-O\nheader.\n\n+----------------------------+-------------------------------------------------------------------------------------------------+\n| Argument | Description |\n+============================+=================================================================================================+\n| ``target_path`` | A path to the target Mach-O executable file. **This file will be overwritten**. |\n+----------------------------+-------------------------------------------------------------------------------------------------+\n| ``library_install_name`` | An install name for the library to inject. This string is used as a part of the load command. |\n+----------------------------+-------------------------------------------------------------------------------------------------+\n\n+-----------------------------------------------------------------------+\n| Return value |\n+=======================================================================+\n| Returns ``True`` if everything is OK. Otherwise rises an exception. |\n+-----------------------------------------------------------------------+\n\n\n\n\t.. code:: python\n\n\t macho_dependencies_list (target_path, header_magic=None)\n\nGenerates a list of libraries the given Mach-O file depends on.\n\nIn that list a single library is represented by its \"install path\": for some\nlibraries it would be a full file path, and for others it would be a relative\npath (sometimes with dyld templates like @executable_path or @rpath in it).\n\nNote: I don't know any reason why would some architectures of a fat Mach-O depend\non certain libraries while others don't, but *it's technically possible*.\nSo that's why you may want to specify the `header_magic` value for a particular header.\n\n+----------------------------+-------------------------------------------------------------------------------------------------+\n| Argument | Description |\n+============================+=================================================================================================+\n| ``target_path`` | A path to the target Mach-O executable file. |\n+----------------------------+-------------------------------------------------------------------------------------------------+\n| ``header_magic`` | Mach-O MAGIC value for a header you want to inspect. If this argument is not provided, the |\n| | function returns a list of the first header's dependencies. |\n+----------------------------+-------------------------------------------------------------------------------------------------+\n\n+-----------------------------------------------------------------------+\n| Return value |\n+=======================================================================+\n| An object with two properties: ``weak`` and ``strong`` that hold lists|\n| of weak and strong dependencies respectively. |\n+-----------------------------------------------------------------------+\n\nSee ``machobot/tests/test_dylib.py`` for usage examples.\n\n--------------\n\nFound an issue? Submit an issue! :shipit:", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://github.com/rodionovd/machobot", "keywords": null, "license": "MIT", "maintainer": null, "maintainer_email": null, "name": "machobot", "package_url": "https://pypi.org/project/machobot/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/machobot/", "project_urls": { "Download": "UNKNOWN", "Homepage": "http://github.com/rodionovd/machobot" }, "release_url": "https://pypi.org/project/machobot/0.1.5/", "requires_dist": null, "requires_python": null, "summary": "A set of tools for Mach-O executables analysis on OS X", "version": "0.1.5" }, "last_serial": 1682232, "releases": { "0.1.1": [ { "comment_text": "", "digests": { "md5": "45ae62141d859b445444bf299cd75a6c", "sha256": "da2ccdd83193f9fa332486eedd841b3cc1301513ce920b85b2cf7ba7487bb701" }, "downloads": -1, "filename": "machobot-0.1.1.tar.gz", "has_sig": false, "md5_digest": "45ae62141d859b445444bf299cd75a6c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 2958, "upload_time": "2015-03-30T19:00:14", "url": "https://files.pythonhosted.org/packages/29/af/390eabcc62467efcfd3792065d547a383f9976986df651fa1aad4c2d04d9/machobot-0.1.1.tar.gz" } ], "0.1.2": [ { "comment_text": "", "digests": { "md5": "bc4950e7a65981b590fd367b60097f2a", "sha256": "2eb4ecc35867eba3aa57ad98e53bb4faf5b7fecbb98ed88d565f7f1fc6b634c7" }, "downloads": -1, "filename": "machobot-0.1.2.tar.gz", "has_sig": false, "md5_digest": "bc4950e7a65981b590fd367b60097f2a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3591, "upload_time": "2015-04-03T10:54:26", "url": "https://files.pythonhosted.org/packages/b7/a8/87eab6cc18796b252d3dc76641f87eea1191f5ff9452469d933b3a22fef3/machobot-0.1.2.tar.gz" } ], "0.1.4": [ { "comment_text": "", "digests": { "md5": "d7a69177643ff8c213ec0e7d77b4b4f8", "sha256": "d82154132bc16029fe0acdb0612a6d0a9c5daeb72e9dff803d968a61c5867cbd" }, "downloads": -1, "filename": "machobot-0.1.4.tar.gz", "has_sig": false, "md5_digest": "d7a69177643ff8c213ec0e7d77b4b4f8", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6524, "upload_time": "2015-08-18T12:33:17", "url": "https://files.pythonhosted.org/packages/de/17/38e2a0f8c4e602f996f26a8965d2b8109956bf8a0df79324457349fa848c/machobot-0.1.4.tar.gz" } ], "0.1.5": [ { "comment_text": "", "digests": { "md5": "cbd4f2ee2e4e0b8d5dbcc71648c0ae93", "sha256": "f1f1a26a7551c113b2a421d88ed935e3e1e0f4e1b24c8b96bf5ca5b1dbb505c4" }, "downloads": -1, "filename": "machobot-0.1.5.tar.gz", "has_sig": false, "md5_digest": "cbd4f2ee2e4e0b8d5dbcc71648c0ae93", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6528, "upload_time": "2015-08-18T12:40:42", "url": "https://files.pythonhosted.org/packages/8a/44/19de619226c3f3962858f4b4913753c635e97d7c1b32364b31360949ca48/machobot-0.1.5.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "cbd4f2ee2e4e0b8d5dbcc71648c0ae93", "sha256": "f1f1a26a7551c113b2a421d88ed935e3e1e0f4e1b24c8b96bf5ca5b1dbb505c4" }, "downloads": -1, "filename": "machobot-0.1.5.tar.gz", "has_sig": false, "md5_digest": "cbd4f2ee2e4e0b8d5dbcc71648c0ae93", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6528, "upload_time": "2015-08-18T12:40:42", "url": "https://files.pythonhosted.org/packages/8a/44/19de619226c3f3962858f4b4913753c635e97d7c1b32364b31360949ca48/machobot-0.1.5.tar.gz" } ] }