PHPackages                             niif/simplesamlphp-module-attributecollector - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. niif/simplesamlphp-module-attributecollector

ActiveSimplesamlphp-module[Utility &amp; Helpers](/categories/utility)

niif/simplesamlphp-module-attributecollector
============================================

Collect attributes from backend databases like sql or ldap

v1.0.0(10y ago)11123PHP

Since Feb 28Pushed 4y ago7 watchersCompare

[ Source](https://github.com/NIIF/simplesamlphp-module-attributecollector)[ Packagist](https://packagist.org/packages/niif/simplesamlphp-module-attributecollector)[ RSS](/packages/niif-simplesamlphp-module-attributecollector/feed)WikiDiscussions master Synced 2mo ago

READMEChangelog (1)Dependencies (1)Versions (2)Used By (0)

Attributecollector
==================

[](#attributecollector)

simplesamlphp auth proc filter, that get attributes from backend database and set to attributes array.

This code is delivered from:

Basic configuration
===================

[](#basic-configuration)

Configure this module as an Auth Proc Filter. More info at

Example
=======

[](#example)

In the following example the filter is configured for only one hosted IdP editing the file saml20-idp-hosted

```
$metadata = array(

		'ssp-idp' => array(

		...

				'authproc' => array(
						10 => array(
								'existing' => 'preserve',
								'class' => 'attributecollector:AttributeCollector',
								'uidfield' => 'subject',
								'collector' => array(
										'class' => 'attributecollector:SQLCollector',
										'dsn' => 'pgsql:host=localhost;dbname=ssp-extra',
										'username' => 'ssp-extra',
										'password' => 'ssp-extra',
										'query' => 'SELECT * from extra where subject=:uidfield',
								)
						)
				),

		...

		)
);
```

Configuration Options explained
===============================

[](#configuration-options-explained)

The filter needs the following options:

- class: The filter class. Allways: 'attributecollector:AttributeCollector'
- uidfield: The name of the field used as an unique user identifier. The configured collector recives this uid so it can search for extra attributes.
- collector: The configuration of the collector used to retrieve the extra attributes

The following option is optional:

- existing: Tell the filter what to do when a collected attribute already exists in the user attributes. Values can be: 'preserve': Ignore collected attribute and preserve the old one. This one is the default behaviour. 'replace': Ignore original attribute and replace it with the collected one. 'merge': Merge the collected attribute into the array of the original one.

Collector Configuration Options explained
=========================================

[](#collector-configuration-options-explained)

The collector configuration array needs at least one option:

- class: The collector class.

Some other options may be needed by the collector, refer to the collector documentation.

###  Health Score

30

—

LowBetter than 64% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community14

Small or concentrated contributor base

Maturity63

Established project with proven stability

 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

Unknown

Total

1

Last Release

3731d ago

### Community

Maintainers

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

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

![](https://www.gravatar.com/avatar/58cf0b44aa083da212f27d6c89a3ba7b0716079d39f2d2d845d4997d61e93571?d=identicon)[northway](/maintainers/northway)

---

Top Contributors

[![szabogyula](https://avatars.githubusercontent.com/u/3406217?v=4)](https://github.com/szabogyula "szabogyula (1 commits)")

### Embed Badge

![Health badge](/badges/niif-simplesamlphp-module-attributecollector/health.svg)

```
[![Health](https://phpackages.com/badges/niif-simplesamlphp-module-attributecollector/health.svg)](https://phpackages.com/packages/niif-simplesamlphp-module-attributecollector)
```

PHPackages © 2026

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