PHPackages                             kozz/yii-xss-filter - 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. [Search &amp; Filtering](/categories/search)
4. /
5. kozz/yii-xss-filter

ActiveLibrary[Search &amp; Filtering](/categories/search)

kozz/yii-xss-filter
===================

Yii XSS Filter

1.0.1(11y ago)1400↓100%3BSD-3-ClausePHPPHP &gt;=5.3

Since Oct 1Pushed 11y ago2 watchersCompare

[ Source](https://github.com/urakozz/php-yii-xss-filter)[ Packagist](https://packagist.org/packages/kozz/yii-xss-filter)[ RSS](/packages/kozz-yii-xss-filter/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (2)Dependencies (6)Versions (3)Used By (0)

php-yii-xss-filter
==================

[](#php-yii-xss-filter)

Yii XSS Filter

Фильтр предназначен для фильтрации входных данных, c целью предотвратить xss атаки. Для фильтрации используются регулярные выражения из фреймворка Kohana версии 2.3.4

```
  /**
   * @example
   **/
  public function filters()
  {
    return array(
      array(
        'XssFilter',
        'clean'   => '*',
        'tags'    => 'strict',
        'actions' => 'all'
      )
    );
  }
```

Описание параметров

В качетве параметра 'clean' могут быть:

- 'all' - фильтруются GET,POST,COOKIE,FILES массивы;
- '\*' - аналог ALL;
- так же возможно сочетание любых из параметров, например GET,COOKIE или POST,FILES В качестве параметра 'tags' могут быть:
- 'strict' - ко всем параметрам применяется функция strip\_tags (используется по умолчанию)
- 'soft' - ко всем параметрам применяется функция htmlspecialchars
- 'none' - не фильтровать В качестве параметра 'actions' могут быть:
- '\*' или 'all' - фильтруются все экшены
- можно указать экшены через запятую, пример 'actions' =&gt; 'admin,manage' - фильтровать только экшены admin и manage

###  Health Score

29

—

LowBetter than 60% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity17

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% 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.

###  Release Activity

Cadence

Every ~0 days

Total

2

Last Release

4242d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/8f78e5a1e5128b31ba7dfedcc9a3ccfbc4852f5df1b79a54867aa377169968a1?d=identicon)[urakozz](/maintainers/urakozz)

---

Top Contributors

[![urakozz](https://avatars.githubusercontent.com/u/5797393?v=4)](https://github.com/urakozz "urakozz (15 commits)")

---

Tags

filterxssyiiYiiXss

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/kozz-yii-xss-filter/health.svg)

```
[![Health](https://phpackages.com/badges/kozz-yii-xss-filter/health.svg)](https://phpackages.com/packages/kozz-yii-xss-filter)
```

###  Alternatives

[clue/stream-filter

A simple and modern approach to stream filtering in PHP

1.7k261.7M7](/packages/clue-stream-filter)[laminas/laminas-filter

Programmatically filter and normalize data and files

9428.0M150](/packages/laminas-laminas-filter)[htmlawed/htmlawed

Official htmLawed PHP library for HTML filtering

401.1M9](/packages/htmlawed-htmlawed)[soosyze/kses

An HTML/XHTML filter written in PHP. Checks on attribute values. Can be used to avoid Cross-Site Scripting (XSS), Buffer Overflows and Denial of Service attacks, among other things.

1258.5k1](/packages/soosyze-kses)[lincanbin/white-html-filter

A lightweight php-based HTML tag and attribute whitelist filter.

1215.1k1](/packages/lincanbin-white-html-filter)[cyneek/yii2-routes

Routing and filtering extension system for Yii2 framework that emulates the Laravel routing system.

202.1k](/packages/cyneek-yii2-routes)

PHPackages © 2026

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