ssdeep

package module
v0.0.0-...-963140e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 20, 2020 License: MIT Imports: 3 Imported by: 1

README

gossdeep

Go version of ssdeep [http://ssdeep.sourceforge.net/].

Status

GoDoc

Installation

Installation requires specific CGO_LDFLAGS_ALLOW be set before both go get and compilation.

export CGO_LDFLAGS_ALLOW="^-[Il].*$"
go get github.com/dutchcoders/gossdeep

// use in your .go code
import (
    "github.com/dutchcoders/gossdeep"
)

Usage

hash, err := HashString("test")
if err != nil {
        t.Fatal(err)
}

Contact me

If I can help you, you have an idea or you are using gossdeep in your projects, don't hesitate to drop me a line (or a pull request): @remco_verhoef

About

Written by remco_verhoef.

License

BSD 3-Clause license, as Go language.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Compare

func Compare(str1, str2 string) (int, error)

Computes the match score between two fuzzy hash signatures.

func HashBytes

func HashBytes(b []byte) (string, error)

func HashFilename

func HashFilename(filename string) (string, error)

Compute the fuzzy hash of a file.

func HashString

func HashString(str string) (string, error)

Obtain the fuzzy hash from the state.

Types

type FuzzyState

type FuzzyState struct {
	// contains filtered or unexported fields
}

func New

func New() (*FuzzyState, error)

Construct a fuzzy_state object and return it.

func (*FuzzyState) Clone

func (fs *FuzzyState) Clone() (*FuzzyState, error)

Create a copy of a fuzzy_state object and return it.

func (*FuzzyState) Digest

func (fs *FuzzyState) Digest() (string, error)

Obtain the fuzzy hash from the state.

func (*FuzzyState) Free

func (fs *FuzzyState) Free()

Dispose a fuzzy state.

func (*FuzzyState) Update

func (fs *FuzzyState) Update(str string) error

Feed the data contained in the given buffer to the state.<F37>

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL