https://github.com/wader/fq Skip to content Sign up * Why GitHub? + Features + Mobile + Actions + Codespaces + Packages + Security + Code review + Issues + Integrations + GitHub Sponsors + Customer stories * Team * Enterprise * Explore + Explore GitHub + Learn and contribute + Topics + Collections + Trending + Learning Lab + Open source guides + Connect with others + The ReadME Project + Events + Community forum + GitHub Education + GitHub Stars program * Marketplace * Pricing + Plans + Compare plans + Contact Sales + Education [ ] * # In this repository All GitHub | Jump to | * No suggested jump to results * # In this repository All GitHub | Jump to | * # In this user All GitHub | Jump to | * # In this repository All GitHub | Jump to | Sign in Sign up {{ message }} wader / fq Public * Notifications * Fork 32 * Star 1.8k * jq for binary formats View license 1.8k stars 32 forks Star Notifications * Code * Issues 5 * Pull requests 1 * Actions * Projects 0 * Wiki * Security * Insights More * Code * Issues * Pull requests * Actions * Projects * Wiki * Security * Insights master Switch branches/tags [ ] Branches Tags Could not load branches Nothing to show {{ refName }} default View all branches Could not load tags Nothing to show {{ refName }} default View all tags 2 branches 2 tags Code Latest commit @dundee @wader dundee and wader doc: add install instructions for Arch Linux ... a9f5527 Dec 23, 2021 doc: add install instructions for Arch Linux fixes #19 a9f5527 Git stats * 444 commits Files Permalink Failed to load latest commit information. Type Name Latest commit message Commit time .github/workflows Update github-go-version from 1.17.4, 1.17.4 to 1.17.5 Dec 9, 2021 .vscode tiff: Fix endian typo and cleanup todos Dec 12, 2021 dev snippet: Add mp4_matrix_structure_rotation Nov 19, 2021 doc doc: Remove empty comment Dec 22, 2021 format mp4,ctts: Seem more usable to treat sample count/offset as signed Dec 20, 2021 internal interp: Rework buffer regex support Dec 17, 2021 pkg interp: Rework buffer regex support Dec 17, 2021 .gitignore format: Add vorbis-comment-picture test, add .gitignore and cleanup Nov 21, 2021 .golangci.yml lint: Enable errcheck adnd revive Sep 27, 2021 .goreleaser.yml goreleaser: Cleanup Oct 5, 2021 Bumpfile Update gomod-mapstructure from 1.4.2 to 1.4.3 Dec 2, 2021 Dockerfile Update docker-golang from 1.17.4 to 1.17.5 Dec 10, 2021 LICENSE Add to/bytes/bits[range] Oct 17, 2021 Makefile make: Fix prof build issue Dec 12, 2021 README.md doc: add install instructions for Arch Linux Dec 23, 2021 fq.go fq: Rename main.go to fq.go Dec 3, 2021 go.mod gojq: Update to rebased fq fork Dec 11, 2021 go.sum gojq: Update to rebased fq fork Dec 11, 2021 View code [ ] fq Goals Usage Install Homebrew Arch Linux Build from source Supported formats TODO and ideas Development Thanks and related projects README.md fq Tool, language and decoders for inspecting binary data. fq demo In most cases fq works the same way as jq but instead of reading JSON it reads binary data. The result is a JSON compatible structures where each value has a bit range, symbolic interpretations and know how to be presented in a useful way. NOTE: fq is early in development and many things are missing, broken or do not make sense. That also means there is a great opportunity to help out! Goals * Make binary formats accessible and queryable. * Nested formats and bit-oriented decoding. * Quick and comfortable CLI tool. * Bit and byte transformations and conversions. * Programmer's calculator. Usage Basic usage is fq . file. For details see usage.md Install Download release for your platform, unarchive it and move the executable to PATH etc. Homebrew # install latest release brew install wader/tap/fq Arch Linux yay -S fq # or fq-bin Build from source Make sure you have go 1.17 or later installed. To install directly from git repository do: # build and install latest release go install github.com/wader/fq@latest # or build and install latest master go install github.com/wader/fq@master # copy binary to $PATH if needed cp "$(go env GOPATH)/bin/fq" /usr/local/bin To build and run tests from source directory: make test fq # copy binary to $PATH if needed cp fq /usr/local/bin Supported formats aac_frame, adts, adts_frame, apev2, av1_ccr, av1_frame, av1_obu, avc_annexb, avc_au, avc_dcr, avc_nalu, avc_pps, avc_sei, avc_sps, bzip2, dns, dns_tcp, elf, ether8023_frame, exif, flac, flac_frame, flac_metadatablock, flac_metadatablocks, flac_picture, flac_streaminfo, gif, gzip, hevc_annexb, hevc_au, hevc_dcr, hevc_nalu, icc_profile, icmp, id3v1, id3v11, id3v2, ipv4_packet, jpeg, json, matroska, mp3, mp3_frame, mp4, mpeg_asc, mpeg_es, mpeg_pes, mpeg_pes_packet, mpeg_spu, mpeg_ts, ogg, ogg_page, opus_packet, pcap, pcapng, png, protobuf, protobuf_widevine, pssh_playready, raw, sll2_packet, sll_packet, tar, tcp_segment, tiff, udp_datagram, vorbis_comment, vorbis_packet, vp8_frame, vp9_cfm, vp9_frame, vpx_ccr, wav, webp, xing, zip For details see formats.md TODO and ideas See TODO.md Development See dev.md Thanks and related projects This project would not have been possible without itchyny's jq implementation gojq. I also want to thank HexFiend for inspiration and ideas and stedolan for inventing the jq language. Similar or related projects: * HexFiend * binspector * kaitai * Wireshark (specially tshark -T json) * MediaInfo (specially mediainfo --Output=JSON and mediainfo --Details=1) * GNU poke * ffmpeg/ffprobe * hexdump About jq for binary formats Topics go cli json query binary repl jq decode hexdump Resources Readme License View license Stars 1.8k stars Watchers 13 watching Forks 32 forks Releases 2 v0.0.2 Latest Dec 22, 2021 + 1 release Packages 0 No packages published Contributors 2 * @wader wader Mattias Wadman * @dundee dundee Daniel Milde Languages * Go 95.8% * jq 3.9% * Other 0.3% * (c) 2021 GitHub, Inc. * Terms * Privacy * Security * Status * Docs * Contact GitHub * Pricing * API * Training * Blog * About You can't perform that action at this time. You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.