PHPackages                             vdechenaux/iso-9660 - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [File &amp; Storage](/categories/file-storage)
4. /
5. vdechenaux/iso-9660

ActiveLibrary[File &amp; Storage](/categories/file-storage)

vdechenaux/iso-9660
===================

Stream Wrapper for ISO9660 files (.iso files)

9551[1 PRs](https://github.com/vdechenaux/iso-9660/pulls)PHP

Since May 1Pushed 3y ago1 watchersCompare

[ Source](https://github.com/vdechenaux/iso-9660)[ Packagist](https://packagist.org/packages/vdechenaux/iso-9660)[ RSS](/packages/vdechenaux-iso-9660/feed)WikiDiscussions master Synced today

READMEChangelogDependenciesVersions (1)Used By (0)

ISO9660 Stream Wrapper for PHP
==============================

[](#iso9660-stream-wrapper-for-php)

PHP Stream Wrapper for ISO9660 files (.iso files)

[![CircleCI](https://camo.githubusercontent.com/5c7c5d62206c92bd2b08ece68ca238f796f0c8d12217f10839dbf43f77c4d02b/68747470733a2f2f646c2e636972636c6563692e636f6d2f7374617475732d62616467652f696d672f67682f7664656368656e6175782f69736f2d393636302f747265652f6d61737465722e7376673f7374796c653d737667)](https://dl.circleci.com/status-badge/redirect/gh/vdechenaux/iso-9660/tree/master)[![Coverage Status](https://camo.githubusercontent.com/ce7b301ee03a1934efb9a61ceb297eaf9c55cd70d9e912fe3e197bc62c957d7f/68747470733a2f2f636f766572616c6c732e696f2f7265706f732f6769746875622f7664656368656e6175782f69736f2d393636302f62616467652e7376673f6272616e63683d6d6173746572)](https://coveralls.io/github/vdechenaux/iso-9660?branch=master)

Usage
-----

[](#usage)

Install using Composer:

```
$ composer require vdechenaux/iso-9660

```

Register the Stream Wrapper:

```
\ISO9660\StreamWrapper::register();
```

Use it, with any function which supports stream wrappers:

```
// Get the content
file_get_contents('iso9660://path/myIsoFile.iso#song.mp3');

// Get the size
filesize('iso9660://path/myIsoFile.iso#song.mp3');

// Check if ISO file contains a file
file_exists('iso9660://path/myIsoFile.iso#song.mp3');

// List files
$iterator = new RecursiveTreeIterator(new RecursiveDirectoryIterator('iso9660://myIsoFile.iso#'));
foreach ($iterator as $entry) {
    echo $entry.PHP_EOL;
}

// Get a stream on a file contained in the ISO file
// Here, a PNG file
$stream = fopen('iso9660://myIsoFile.iso#image.png', 'r');
fseek($stream, 1); // Skip 1st byte
$header = fread($stream, 3); // We should get "PNG"

// Etc...
```

You must separate the iso file and the internal path with a `#`, even if the right part is empty, like in above examples.

You can use the `\ISO9660\Reader` class if you don't want to use native PHP functions.

### Custom context options

[](#custom-context-options)

You can configure some behaviors of the reader:

- `showHiddenFiles` (boolean, default: `false`) Set it to `true` to see/read hidden files.

To use options, you have to do something like this:

```
$opts = [
    'iso9660' => [
        'showHiddenFiles'  => true,
    ]
];

$context  = stream_context_create($opts);

file_get_contents('iso9660:///tmp/file.iso#hidden.mp3', false, $context);
```

If you are using the `\ISO9660\Reader` class, you can use theses options by passing an `\ISO9660\ReaderOptions` object to the constructor.

### Read from an optical drive

[](#read-from-an-optical-drive)

As this package is an ISO9660 implementation, you can directly read an optical drive by doing something like this:

```
$iterator = new RecursiveTreeIterator(new RecursiveDirectoryIterator('iso9660:///dev/cdrom#'));
foreach ($iterator as $entry) {
    echo $entry.PHP_EOL;
}
```

By using `/dev/cdrom` instead of an ISO file, you can directly interact with the hardware, without mounting the disc in the OS.

ISO features supported
----------------------

[](#iso-features-supported)

- Basic ISO9660 support
- Joliet support
- SUSP
    - `CE` Continuation Area
    - `SP` System Use Sharing Protocol Indicator
    - `ER` Extensions Reference (supported types: `RRIP_1991A`, `IEEE_P1282`, `IEEE_1282`)
- Rock Ridge support
    - `CL` Child link
    - `PL` Parent link
    - `NM` Alternate name
    - `PX` POSIX file attributes
    - `RE` Relocated directory
    - `RR` Rock Ridge extensions in-use indicator
    - `SL` Symbolic link
    - `TF` Time stamp(s) for a file

Why ?
-----

[](#why-)

Why not ? 🤷‍♂️

I made it only for fun. I hope someone will find a usage 😁

License
-------

[](#license)

This project is released under [the MIT license](LICENSE).

###  Health Score

18

—

LowBetter than 8% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity15

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity23

Early-stage or recently created project

 Bus Factor1

Top contributor holds 94.1% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/e5f5c84812f68e4cc39b81849f0626eb8289210293b4eb0f66c6ee0c5e287fbd?d=identicon)[vdechenaux](/maintainers/vdechenaux)

---

Top Contributors

[![vdechenaux](https://avatars.githubusercontent.com/u/1501825?v=4)](https://github.com/vdechenaux "vdechenaux (16 commits)")[![chrismshelton](https://avatars.githubusercontent.com/u/633045?v=4)](https://github.com/chrismshelton "chrismshelton (1 commits)")

---

Tags

cdromisoiso9660jolietphprockridgestream-wrapper

### Embed Badge

![Health badge](/badges/vdechenaux-iso-9660/health.svg)

```
[![Health](https://phpackages.com/badges/vdechenaux-iso-9660/health.svg)](https://phpackages.com/packages/vdechenaux-iso-9660)
```

###  Alternatives

[venveo/craft-compress

Create smart zip files from Craft assets on the fly

124.7k](/packages/venveo-craft-compress)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
