{"id":32197062,"url":"https://github.com/0x09/hfsfuse","last_synced_at":"2026-03-04T21:03:38.365Z","repository":{"id":54640886,"uuid":"49255227","full_name":"0x09/hfsfuse","owner":"0x09","description":"FUSE driver for HFS+ filesystems","archived":false,"fork":false,"pushed_at":"2026-03-04T02:37:09.000Z","size":1130,"stargazers_count":103,"open_issues_count":3,"forks_count":15,"subscribers_count":3,"default_branch":"master","last_synced_at":"2026-03-04T06:40:41.354Z","etag":null,"topics":["driver","fuse","fuse-filesystem","hfs","hfs-filesystems"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/0x09.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"COPYING","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2016-01-08T06:49:26.000Z","updated_at":"2026-03-04T02:37:13.000Z","dependencies_parsed_at":"2023-12-29T23:29:30.915Z","dependency_job_id":"ec1cdda3-08b7-492b-bd90-60de012934e7","html_url":"https://github.com/0x09/hfsfuse","commit_stats":null,"previous_names":[],"tags_count":25,"template":false,"template_full_name":null,"purl":"pkg:github/0x09/hfsfuse","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0x09%2Fhfsfuse","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0x09%2Fhfsfuse/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0x09%2Fhfsfuse/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0x09%2Fhfsfuse/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/0x09","download_url":"https://codeload.github.com/0x09/hfsfuse/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0x09%2Fhfsfuse/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30092887,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-04T20:42:30.420Z","status":"ssl_error","status_checked_at":"2026-03-04T20:42:30.057Z","response_time":59,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["driver","fuse","fuse-filesystem","hfs","hfs-filesystems"],"created_at":"2025-10-22T02:49:45.631Z","updated_at":"2026-03-04T21:03:38.356Z","avatar_url":"https://github.com/0x09.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"[FUSE](https://github.com/libfuse/libfuse) driver for HFS+ filesystems, based on NetBSD's kernel driver with modifications.\n\nhfsfuse embeds and extends [NetBSD's HFS+ kernel driver](http://cvsweb.netbsd.org/bsdweb.cgi/src/sys/fs/hfs/) into a portable library for use with FUSE and other userspace tools. hfsfuse was created for use on FreeBSD and other Unix-like systems that lack a native HFS+ driver, but can also be used on Linux and macOS as an alternative to their kernel drivers.\n\nhfsfuse also includes two standalone tools, hfsdump and hfstar, which can be used without FUSE.\n\nThis driver and tools are read-only and cannot write to or alter the target filesystem.\n\n**Supported**\n\n* Journaled and non-journaled HFS+\n* Unicode normalization for pathnames via utf8proc\n* Hard links, including directory hard links (i.e. Time Machine backups)\n* Resource fork, Finder info, and creation/backup time access via extended attributes\n* birthtime (with compatible FUSE)\n* User-defined extended attributes\n* HFS+ compression with zlib, lzvn, and lzfse\n\n**Not supported**\n\n* HFS without the \"+\", aka \"Mac OS Standard\" volumes. For these, try [hfsutils](https://www.mars.org/home/rob/proj/hfs/).\n* Writing\n\n# Installation\nWith the FUSE headers and library for your platform installed, running `make install` (gmake on *BSD) from the project root will build and install hfsfuse and related tools and should be sufficient for most use cases. See below for more details or skip to [usage](#Use).\n\n## Dependencies\nhfsfuse aims to be widely portable across Unix-like systems. Build requirements include GNU Make, a C11 compiler with a GCC-compatible frontend, and a POSIX-compatible shell and utilities.\n\nhfsfuse's supporting libraries and standalone hfsdump tool require only a POSIX-2008 compatible libc, and can also be built natively on Windows with either Mingw-w64 or msys2.\n\nThe FUSE driver requires a version 2 or 3 compatible FUSE library, and is known to work with the following implementations:\n\n* [libfuse](https://libfuse.github.io) on Linux and *BSD\n* [macFUSE](https://osxfuse.github.io)\n* [FUSE-T](https://www.fuse-t.org)\n* Haiku's userland_fs\n\nhfsfuse optionally uses these additional libraries to enable certain functionality:\n\n* [utf8proc](http://julialang.org/utf8proc/) for working with non-ASCII pathnames\n* [ublio](https://www.freshports.org/devel/libublio/) for read caching, which may improve performance\n* [zlib](https://www.zlib.net), [lzfse](https://github.com/0x09/lzfse), and [lzvn](https://github.com/xerub/LZVN) for reading files with HFS+ compression\n\nutf8proc, ublio, and LZVN are each bundled with hfsfuse and built by default. hfsfuse can be configured to use already-installed versions of these if available, or may be built without them entirely if the respective functionality is not needed (see [Configuring](#Configuring)).\n\nhfstar additionally requires [libarchive](https://www.libarchive.org). Like hfsdump it can also be built for Windows with Mingw-w64 or msys2.\n\n## Configuring\nhfsfuse is configured by passing options directly to `make`, and separate configure and build steps are not needed. `make showconfig` can be used to print available make options and their current values.  \nFor repeated builds using the same options, or to more easily edit config values, `make config` can optionally be used to generate a config.mak file which will be used by future invocations.\n\nTo configure hfsfuse's optional utf8proc, ublio, and LZVN dependencies, use WITH_*DEP*=(none/local/system). The default behavior with no arguments is to use the bundled versions of these and is the same as using\n\n    make WITH_UBILIO=local WITH_UTF8PROC=local WITH_LZVN=local\n\nTo ease portability, the Makefile will attempt to detect certain features of the host libc in an autoconf-like way, and creates a series of defines for these labeled HAVE_*FEATURENAME*. To override and skip checks for a given feature, these may be provided directly to `make` or overridden in config.mak.\n\n## Building\nThe default `make` and `make install` targets build and install hfsfuse, hfsdump, and hfstar. hfsdump and hfstar can also be built standalone with `make hfsdump hfstar`, in which case FUSE is not needed.\n\nhfsfuse's supporting libraries can be built and installed independently using `make lib` and `make install-lib`. Applications can use these to read from HFS+ volumes by including [hfsuser.h](lib/libhfsuser/hfsuser.h) and linking with libhfsuser, libhfs, and ublio/utf8proc/LZVN if configured.  \nA pkg-config file is provided and linker flags can be gotten with `pkg-config --libs --static libhfsuser`.\n\nSome version information is generated from the git repository. For distributions outside of revision control, run `make version` within the repository first or provide your own version.h.\n\n# Use\n## hfsfuse\nhfsfuse is the FUSE driver and is invoked similarly to the Unix mount command.\nhfsfuse accepts an HFS+ volume (device or image), mount point, and a series of options to be passed along to FUSE.  \nUse `hfsfuse -h` for general options or `hfsfuse -H` for a list of all switches supported by FUSE. hfsfuse-specific options are shown below.\n\n    usage: hfsfuse [-hHv] [-o options] volume mountpoint\n\n    general options:\n        -o opt,[opt...]        mount options\n        -h, --help             this help\n        -H, --fullhelp         list all FUSE options\n        -v, --version\n    \n    HFS+ options:\n        --force                force mount volumes with dirty journal\n        -o rsrc_only           only mount the resource forks of files\n        -o cache_size=N        size of lookup cache (1024)\n        -o blksize=N           set a custom read size/alignment in bytes\n                               you should only set this if you are sure it is being misdetected\n        -o rsrc_ext=suffix     special suffix for filenames which can be used to access their resource fork\n                               or alternatively their data fork if mounted in rsrc_only mode\n    \n        -o default_file_mode=N octal filesystem permissions for Mac OS Classic files (755)\n        -o default_dir_mode=N  octal filesystem permissions for Mac OS Classic directories (777)\n        -o default_uid=N       unix user ID for Mac OS Classic files (0)\n        -o default_gid=N       unix group ID for Mac OS Classic files (0)\n\n        -o disable_symlinks    treat symbolic links as regular files. may be used to view extended attributes\n                               of these on systems that don't support symlink xattrs\n    \n        -o noublio             disable ublio read layer\n        -o ublio_items=N       number of ublio cache entries, 0 for no caching (64)\n        -o ublio_grace=N       reclaim cache entries only after N requests (32)\n    \nNote for Haiku users: under Haiku, FUSE applications cannot be invoked directly. Instead, `make install` will install hfsfuse as a userlandfs add-on, which can be loaed with:\n\n    /system/servers/userlandfs_server hfsfuse\n\nAfterwards filesystems may be mounted like so:\n\n    mount -t userlandfs -o \"hfsfuse \u003copts\u003e \u003cdevice\u003e\" \u003cmountpoint\u003e\n\n## hfsdump\nhfsdump is a small standalone tool which can be used to inspect the contents of an HFS+ volume by printing record info and file or directory contents to standard out.\n\n    Usage: hfsdump \u003cdevice\u003e \u003cstat|read|xattr\u003e \u003cpath|inode\u003e [xattrname]\n\t\n`stat`, `read`, and `xattr` are commands to perform. `stat` prints the record structure, while `read` copies the node's contents to standard out (or lists if node is a directory).  \nThe `xattr` command lists extended attribute names for the given node. If an attribute name is provided following the node argument, its value will be printed to standard out.  \n`inode` or `path` are either an integer inode/CNID to lookup, or a full path from the root of the volume being inspected.  \nIf the command and node are ommitted, hfsdump prints the volume header and exits.  \n`/rsrc` may be appended to the path of a read operation to dump the resource fork instead.  \n\n## hfstar\nhfstar can be used to archive the contents of an HFS+ volume to tar or any other archive format supported by libarchive.\n\n    Usage: hfstar [options] \u003cvolume\u003e \u003carchive\u003e [\u003cprefix\u003e]\n    \n      \u003cvolume\u003e   HFS+ image or device to convert.\n      \u003carchive\u003e  Output archive file.\n      \u003cprefix\u003e   Optional path in the HFS+ volume to archive. Default: /\n    \n    Options:\n      -h, --help\n      -v, --version\n    \n      -b \u003cbufsize\u003e  Size of read buffer. Default: device's block size or 16kb for regular files.\n      -s            Archive directory hard links as symbolic links instead of resolving them.\n      -t            Trim \u003cprefix\u003e from archived paths. The root entry will be omitted.\n      -e            Stop archiving if any entry has an error.\n      -p            Print paths being archived.\n      -W            Silence warnings.\n    \n    libarchive options:\n      --format \u003cname\u003e   Name of the archive format. May be any format accepted by libarchive.\n                        Default: inferred from the output archive file extension.\n                        For .tar or no extension, defaults to posix format.\n      --filter \u003cname\u003e   Name of a libarchive filter. Default: inferred from the output file extension.\n      --options \u003copts\u003e  String of libarchive options in the format option=value,...\n    \n    HFS+ options:\n      --force           Try to read volumes with a dirty journal\n      --blksize \u003cn\u003e     Device block size. Default: autodetected.\n      --rsrc-ext \u003cext\u003e  Archive resource forks as separate files with this extension, instead of as an xattr.\n    \n      --default-file-mode \u003cmode\u003e  Octal filesystem permissions for Mac OS Classic files. Default: 755\n      --default-dir-mode \u003cmode\u003e   Octal filesystem permissions for Mac OS Classic directories. Default: 777\n      --default-uid \u003cuid\u003e         Unix user ID for Mac OS Classic files. Default: 0\n      --default-gid \u003cgid\u003e         Unix group ID for Mac OS Classic files. Default: 0\n    \n      --noublio          Disable ublio read layer.\n      --ublio-items \u003cN\u003e  Number of ublio cache entries, 0 for no caching. Default: 64\n      --ublio-grace \u003cN\u003e  Reclaim cache entries only after N requests. Default: 32\n\n\nFor tar archives, hfstar defaults to the `posix` format for compatibility with the most HFS+ attributes. This can be overridden with the `--format` option.  \nWhen archiving to a format that supports extended attributes, hfstar includes any user-defined extended attributes as well as the automatic xattrs described [below](#extended-attributes-and-resource-forks).\nIn addition to hfsfuse.record.date_created, file creation times are stored using libarchive's LIBARCHIVE.creationtime attribute.\n\nBy default, files' resource fork data is archived in the com.apple.ResourceFork extended attribute. This may optionally instead be archived to independent files with a special suffix using the `--rsrc-ext` option.\n\nAny directory hard links are resolved by default, which duplicates their content in the archive. These can be converted into symbolic links instead with `-s`.\n\nhfstar is about 50% faster than archiving from a filesystem mounted with hfsfuse. hfstar can also be used to extract an HFS+ volume onto the local filesystem with a command like:\n\n```shell\nhfstar \u003cvolume\u003e - | tar --xattrs -C \u003cdest\u003e -xf -`\n```\n\n## Extended attributes and resource forks\nhfsfuse exposes some nonstandard HFS+ attributes as extended attributes. These include:\n\n* hfsfuse.record.date\\_created: The date created as an ISO-8601 timestamp, displayed in localtime with the time zone offset. Identical to `st_birthtime` on macOS or FreeBSD.\n* hfsfuse.record.date\\_backedup: The backup time of a file in the same format as hfsfuse.record.date\\_created.\n* com.apple.FinderInfo: The Finder info as binary data, presented the same as with the macOS native driver.\n* com.apple.ResourceFork: The resource fork as binary data.\n\nThe resource fork may also be accessed during normal use by defining a special file suffix with the `rsrc_ext` option. When this is set, any lookup that ends in this suffix returns resource fork data for the corresponding file. For example, when mounting with `-orsrc_ext=.rsrc`, \"image.psd.rsrc\" can be used to access the resource fork for image.psd.  \nOf course, \"image.psd.rsrc\" may also exist independently, so this option can be set to anything suitable (`:rsrc`, `-resource`, etc) with the only condition being that it cannot include a path separator (as FUSE intercepts these).  \nBecause of this, the more familiar `/rsrc` suffix used by previous releases of macOS is not supported in hfsfuse, but may still be used with hfsdump.\n\nFinally, the entire volume may be mounted in resource-fork only mode using the `rsrc_only` option. In this mode, all entries on the filesystem are presented using the size and contents of their resource fork. Files with no resource fork will appear as empty, 0 size entries.  \nThis option may be combined with the `rsrc_ext` option described above, in which case the special suffix will instead be used to access the regular data fork.\n\n### OS-specific extended attribute behavior\nOn Linux you may encounter the following error when inspecting xattrs: `user.com.apple.ResourceFork: Argument list too long`  \nThis occurs when the resource fork is larger than the maximum allowed extended attribute size of 64kb. In this case you can still access the resource fork as described above by setting the `rsrc_ext` option or mounting in `rsrc_only` mode.\n\nUnder Haiku only, all extended attribute values are hex encoded to allow binary attribute data to be passed along from FUSE. Values may be read using a tool like xxd, e.g. to read the resource fork extended attribute for \"file\":\n\n```shell\ncatattr -r user.com.apple.ResourceFork file | xxd -r -p\n```\n\nExtended attributes are presented in the preferred namespace for the OS, typically `user.`. Alternate namespaces may be chosen when building hfsfuse by setting the `XATTR_NAMESPACE` make var.  \nThis should include the trailing `.` as an empty value indicates no namespacing (such as on macOS.)\n\nHFS+ symbolic links may contain extended attributes of their own separate from their link destination.\nFor systems such as Linux that do not support reading user-namespace extended attributes of symlinks, these can be viewed by using the `-o disable_symlinks` mount option, which will cause hfsfuse to display all symlinks as regular files.\n\n## Mac OS Classic file permissions\nHFS+ filesystems created on Mac OS Classic do not contain the typical set of Unix ownership and permission information for files and folders.\nFor these hfsfuse provides the options default_file_mode, default_dir_mode, default_uid, and default_gid to specify fallback values if needed.\n\nThese defaults only apply to filesystem entries that are missing this information, they don't affect files or folders with existing permissions.\nThey are applied before the FUSE uid, gid, and umask options or any fuse-idmap conversions and will still be subject to them.\n\n# Other\n## DMG mounting\nDisk images can be mounted using [dmg2img](http://vu1tur.eu.org/dmg2img).\n\nOne-liner to extract the HFS+ partition in a DMG to an img:\n\n\tdmg2img -p $(dmg2img -l image.dmg | grep Apple_HFS | cut -d' ' -f2 | cut -d: -f1) image.dmg image.img\n\nThe resulting .img can be mounted directly with `hfsfuse image.img \u003cmountpoint\u003e`\n\n## ID re-mapping\nWhen sharing a disk between systems it's often convenient to establish a mapping between corresponding users/groups. FUSE offers `uid` and `gid` options to force ownership of all files on the mounted system to the provided id, but more involved mappings for multiple users or specific user and group combinations can be done using the [idmap](https://github.com/0x09/fuse-idmap) FUSE module.\n\n# Resources\n* [sys/fs/hfs/ in the NetBSD source tree](http://cvsweb.netbsd.org/bsdweb.cgi/src/sys/fs/hfs/)\n* [Apple Technical Note 1150](https://developer.apple.com/legacy/library/technotes/tn/tn1150.html)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F0x09%2Fhfsfuse","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F0x09%2Fhfsfuse","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F0x09%2Fhfsfuse/lists"}