Git Product home page Git Product logo

Comments (4)

heggiz avatar heggiz commented on May 16, 2024 1

Version v1.0.12 works. Thanks for fixing this so quick!

from filetype.

h2non avatar h2non commented on May 16, 2024

Can you try it now with the latest version v1.0.11?

from filetype.

heggiz avatar heggiz commented on May 16, 2024

It works with version v1.0.11

I have also discovered 2 new crashers when matching tiff files.

panic: runtime error: index out of range

goroutine 1 [running]:
github.com/h2non/filetype/matchers.Tiff.func2(...)
	/home/<name>/gocode/src/github.com/h2non/filetype/matchers/image.go:88
github.com/h2non/filetype/matchers.Tiff(0x7fae06933000, 0x4, 0x4, 0x4a3070)
	/home/<name>/gocode/src/github.com/h2non/filetype/matchers/image.go:90 +0xf6
github.com/h2non/filetype/matchers.NewMatcher.func1(0x7fae06933000, 0x4, 0x4, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
	/home/<name>/gocode/src/github.com/h2non/filetype/matchers/matchers.go:26 +0x81
gopkg.in/h2non/filetype%2ev1.Match(0x7fae06933000, 0x4, 0x4, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
	/home/<name>/gocode/src/gopkg.in/h2non/filetype.v1/match.go:29 +0x206
gopkg.in/h2non/filetype%2ev1.Get(...)
	/home/<name>/gocode/src/gopkg.in/h2non/filetype.v1/match.go:40
github.com/h2non/filetype.Fuzz(0x7fae06933000, 0x4, 0x4, 0x3)
	/home/<name>/gocode/src/github.com/h2non/filetype/fuzz.go:9 +0x7a
go-fuzz-dep.Main(0xc000075f80, 0x1, 0x1)
	/tmp/go-fuzz-build945427859/goroot/src/go-fuzz-dep/main.go:36 +0x1b6
main.main()
	/tmp/go-fuzz-build945427859/gopath/src/github.com/h2non/filetype/go.fuzz.main/main.go:15 +0x52
exit status 2
panic: runtime error: index out of range

goroutine 1 [running]:
github.com/h2non/filetype/matchers.Tiff.func4.1(...)
	/home/<name>/gocode/src/github.com/h2non/filetype/matchers/image.go:90
github.com/h2non/filetype/matchers.Tiff.func4(0x7fa741918000, 0x9, 0x9, 0x511001)
	/home/<name>/gocode/src/github.com/h2non/filetype/matchers/image.go:90 +0xac
github.com/h2non/filetype/matchers.Tiff(0x7fa741918000, 0x9, 0x9, 0x4c80f0)
	/home/<name>/gocode/src/github.com/h2non/filetype/matchers/image.go:90 +0xbb
github.com/h2non/filetype/matchers.NewMatcher.func1(0x7fa741918000, 0x9, 0x9, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
	/home/<name>/gocode/src/github.com/h2non/filetype/matchers/matchers.go:26 +0x81
gopkg.in/h2non/filetype%2ev1.Match(0x7fa741918000, 0x9, 0x9, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
	/home/<name>/gocode/src/gopkg.in/h2non/filetype.v1/match.go:29 +0x247
gopkg.in/h2non/filetype%2ev1.Get(...)
	/home/<name>/gocode/src/gopkg.in/h2non/filetype.v1/match.go:40
github.com/h2non/filetype.Fuzz(0x7fa741918000, 0x9, 0x9, 0x3)
	/home/<name>/gocode/src/github.com/h2non/filetype/fuzz.go:9 +0x7a
go-fuzz-dep.Main(0xc000049f80, 0x1, 0x1)
	/tmp/go-fuzz-build945427859/goroot/src/go-fuzz-dep/main.go:36 +0x1b6
main.main()
	/tmp/go-fuzz-build945427859/gopath/src/github.com/h2non/filetype/go.fuzz.main/main.go:15 +0x52
exit status 2

tiff_crashers.zip

from filetype.

h2non avatar h2non commented on May 16, 2024

Thanks for the heads up! Can you upgrade to v1.0.12?

from filetype.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.