ppdeep


Nameppdeep JSON
Version 20200505 PyPI version JSON
download
home_pagehttps://github.com/elceef/ppdeep
SummaryPure-Python library for computing fuzzy hashes (ssdeep)
upload_time2020-05-05 11:04:29
maintainer
docs_urlNone
authorMarcin Ulikowski
requires_python
license
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            ppdeep
======

This is a pure-Python library for computing context triggered piecewise hashes
(CTPH), also called fuzzy hashes, or often ssdeep after the name of a popular
tool. At a very high level, fuzzy hashing is a way to determine whether two
inputs are similar, rather than identical. Fuzzy hashes are widely adopted in
digital forensics and malware detection.

This implementation is based on SpamSum by Dr. Andrew Tridgell.

Usage
-----

To compute a fuzzy hash, simply use `hash()` function:

```
>>> import ppdeep
>>> h1 = ppdeep.hash('The equivalence of mass and energy translates into the well-known E = mc²')
>>> h1
'3:RC0qYX4LBFA0dxEq4z2LRK+oCKI9VnXn:RvqpLB60dx8ilK+owX'
>>> h2 = ppdeep.hash('The equivalence of mass and energy translates into the well-known E = MC2')
>>> h2
'3:RC0qYX4LBFA0dxEq4z2LRK+oCKI99:RvqpLB60dx8ilK+oA'
```

To calculate level of similarity, use `compare()` function which returns an
integer value from 0 to 100 (full match):

```
>>> ppdeep.compare(h1, h2)
29
```

Function `hash_from_file()` accepts a filename as argument and calculates the
hash of the contents of the file:

```
>>> ppdeep.hash_from_file('.bash_history')
'1536:EXM36dG36x3KW732vOAcg3EP1qKlKozcK0z5G+lEPTssl/7eO7HOBF:tKlKozcWT0'
```

Installation
------------

```
$ pip install ppdeep
```

If you want to use the latest version of the code, you can install it from Git:

```
$ git clone https://github.com/elceef/ppdeep.git
$ cd ppdeep
$ pip install .
```



            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/elceef/ppdeep",
    "name": "ppdeep",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "",
    "author": "Marcin Ulikowski",
    "author_email": "marcin@ulikowski.pl",
    "download_url": "https://files.pythonhosted.org/packages/64/ad/ca722788606970d227b1778c158d4a04ffd8190487fa80b3273e3fa587ac/ppdeep-20200505.tar.gz",
    "platform": "",
    "description": "ppdeep\n======\n\nThis is a pure-Python library for computing context triggered piecewise hashes\n(CTPH), also called fuzzy hashes, or often ssdeep after the name of a popular\ntool. At a very high level, fuzzy hashing is a way to determine whether two\ninputs are similar, rather than identical. Fuzzy hashes are widely adopted in\ndigital forensics and malware detection.\n\nThis implementation is based on SpamSum by Dr. Andrew Tridgell.\n\nUsage\n-----\n\nTo compute a fuzzy hash, simply use `hash()` function:\n\n```\n>>> import ppdeep\n>>> h1 = ppdeep.hash('The equivalence of mass and energy translates into the well-known E = mc\u00b2')\n>>> h1\n'3:RC0qYX4LBFA0dxEq4z2LRK+oCKI9VnXn:RvqpLB60dx8ilK+owX'\n>>> h2 = ppdeep.hash('The equivalence of mass and energy translates into the well-known E = MC2')\n>>> h2\n'3:RC0qYX4LBFA0dxEq4z2LRK+oCKI99:RvqpLB60dx8ilK+oA'\n```\n\nTo calculate level of similarity, use `compare()` function which returns an\ninteger value from 0 to 100 (full match):\n\n```\n>>> ppdeep.compare(h1, h2)\n29\n```\n\nFunction `hash_from_file()` accepts a filename as argument and calculates the\nhash of the contents of the file:\n\n```\n>>> ppdeep.hash_from_file('.bash_history')\n'1536:EXM36dG36x3KW732vOAcg3EP1qKlKozcK0z5G+lEPTssl/7eO7HOBF:tKlKozcWT0'\n```\n\nInstallation\n------------\n\n```\n$ pip install ppdeep\n```\n\nIf you want to use the latest version of the code, you can install it from Git:\n\n```\n$ git clone https://github.com/elceef/ppdeep.git\n$ cd ppdeep\n$ pip install .\n```\n\n\n",
    "bugtrack_url": null,
    "license": "",
    "summary": "Pure-Python library for computing fuzzy hashes (ssdeep)",
    "version": "20200505",
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "md5": "ecb2c108be34fc745f826a4386dbd239",
                "sha256": "0335063cc96edfb2f90f546a5812c4a47d122dc7bd764b3eef48303d2bf41939"
            },
            "downloads": -1,
            "filename": "ppdeep-20200505-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "ecb2c108be34fc745f826a4386dbd239",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 4600,
            "upload_time": "2020-05-05T11:04:28",
            "upload_time_iso_8601": "2020-05-05T11:04:28.230129Z",
            "url": "https://files.pythonhosted.org/packages/a1/88/f652889bc15f3faa9fd973cfa652098dfcfdd6fca6de63bbe1a418734ddb/ppdeep-20200505-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "md5": "8d035df6343671d3579217a80c920cb3",
                "sha256": "acc74bb902e6d21b03d39aed740597093c6562185bfe06da9b5272e01c80a1ff"
            },
            "downloads": -1,
            "filename": "ppdeep-20200505.tar.gz",
            "has_sig": false,
            "md5_digest": "8d035df6343671d3579217a80c920cb3",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 4309,
            "upload_time": "2020-05-05T11:04:29",
            "upload_time_iso_8601": "2020-05-05T11:04:29.361490Z",
            "url": "https://files.pythonhosted.org/packages/64/ad/ca722788606970d227b1778c158d4a04ffd8190487fa80b3273e3fa587ac/ppdeep-20200505.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2020-05-05 11:04:29",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "github_user": "elceef",
    "github_project": "ppdeep",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "ppdeep"
}
        
Elapsed time: 0.02224s