PHPackages                             bkon/sisyphus - 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. bkon/sisyphus

ActiveLibrary

bkon/sisyphus
=============

PHP implementation of Canonical XML and Exclusive XML Canonicalization standards

0111PHP

Since May 1Pushed 12y agoCompare

[ Source](https://github.com/bkon/sisyphus)[ Packagist](https://packagist.org/packages/bkon/sisyphus)[ RSS](/packages/bkon-sisyphus/feed)WikiDiscussions master Synced 4w ago

READMEChangelogDependenciesVersions (1)Used By (0)

[![Build Status](https://camo.githubusercontent.com/d79cdc8bbf077ef1ade5c3e1f14c113c8aa4fe56c562a586ae9d4de57664c4d9/68747470733a2f2f7472617669732d63692e6f72672f626b6f6e2f73697379706875732e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/bkon/sisyphus)

Sisyphus::C14N
==============

[](#sisyphusc14n)

This library provides a pure-PHP implementation of the following standards:

- Canonical XML Version 1.0 ()
- Exclusive XML Canonicalization Version 1.0 ()

Use cases
---------

[](#use-cases)

Consider using this library if you need XML canonicalization on the legacy PHP versions (PHP 5.1.x). If you work with PHP 5.2+, you already have libxml-based canonicalization functionality available as DOMNode::C14n().

PHP 5.1 as a target platform means we don't have access to nice features, like namespaces, lambdas or composer. Don't blame be if this code looks outdated to you. :)

Note that you can easily migrate from pure-PHP implementation to Lixml-based one when you upgrade your infrastructure by simply replacing Sisyphus\_C14n\_Legacy with Sisyphus\_C14n\_Libxml.

Dependencies
------------

[](#dependencies)

Runtime: PHP 5.1

Development: ant, phpunit, phpmd, phpcs, hhvm and hhvm-wrapper, phpcpd, phpdoc.

### PHP 5.3+

[](#php-53)

If your using PHP 5.2+ you won't need this package, but it's available as a composer package anyway.

```
composer install
```

Basic usage
-----------

[](#basic-usage)

```
$service = new Sisyphus_C14n_Legacy();

$service
    ->withComments(false)
    ->exclusive(true)
    ->query('//n1:element')
    ->namespaces(array('n1' => 'http://n1.example.com'))
    ->inclusiveNamespaces(array('n1'));

$outputString = $service->canonicalize($xmlDocument)

```

[![Bitdeli Badge](https://camo.githubusercontent.com/eec0337eb10b4e252c8316bf8e5d86edc0ae013d230a6cc204d95585b0f6723b/68747470733a2f2f64327765637a68766c38323376302e636c6f756466726f6e742e6e65742f626b6f6e2f73697379706875732f7472656e642e706e67)](https://bitdeli.com/free "Bitdeli Badge")

###  Health Score

21

—

LowBetter than 19% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor2

2 contributors hold 50%+ of commits

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://avatars.githubusercontent.com/u/383808?v=4)[Konstantin](/maintainers/bkon)[@bkon](https://github.com/bkon)

---

Top Contributors

[![bkon](https://avatars.githubusercontent.com/u/383808?v=4)](https://github.com/bkon "bkon (6 commits)")[![elliotchance](https://avatars.githubusercontent.com/u/927418?v=4)](https://github.com/elliotchance "elliotchance (6 commits)")[![bitdeli-chef](https://avatars.githubusercontent.com/u/3092978?v=4)](https://github.com/bitdeli-chef "bitdeli-chef (1 commits)")

### Embed Badge

![Health badge](/badges/bkon-sisyphus/health.svg)

```
[![Health](https://phpackages.com/badges/bkon-sisyphus/health.svg)](https://phpackages.com/packages/bkon-sisyphus)
```

PHPackages © 2026

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