This release includes 2 security fixes for security teams reviewing exposed deployments.
Topics
Affected surfaces
Summary
AI summaryUpdates π οΈ Improvements, β¬οΈ Upgrade notes, and π Security fixes across a mixed release.
Full changelog
What's Changed
This is a maintenance and security release on the 3.2.1 line. It closes a folder authorization advisory, fixes a personal-item key redistribution that could expose other users' personal credentials, makes Active Directory group β role mapping work again (broken since 3.1.7.2) with full nested-group support, and aligns the API folder rights with the web interface. Upgrading is recommended for all installations, and required for anyone using Active Directory group mapping or personal folders.
No new feature has to be enabled and no table is altered: the upgrade only runs two one-shot, idempotent data migrations (see Upgrade notes).
π Security fixes
- Missing authorization in the
update_folderaction (GHSA-66q9-mxf2-xqw6) -folders.queries.phphad no authenticated-session gate, andupdate_foldernever checked that the caller could access the folder it was modifying. Any authenticated non-read-only user could re-parent an arbitrary folder and convert it to personal, moving another team's credential subtree into their own personal space and hiding it from the whole organization. The handler is now behind a global session gate, the target folder and the new parent must both belong to the caller's accessible folders, and cross-domain (shared β personal) moves are rejected. - Personal items disclosed to other users through key generation - since the personal-folder fix of 3.2.1.0, the internal recovery account holds a decryption key on every personal item. The "the owner has no sharekey" guard used by
create_user_keystherefore stopped protecting other users' personal items: every account whose keys were (re)generated inherited a valid key on all existing personal items, which surfaced other people's personal credentials, in the Security Posture scan, for example. Key generation now excludes other users' personal folders at every step, the posture queries are scoped by folder as well as by sharekey, and the remediation also covers items stored in a personal folder whosepersoflag was still0. Existing data is cleaned automatically during the upgrade (see Upgrade notes).
π οΈ Improvements
- Active Directory group mapping fixed and nested groups supported (PR #5302, @RealPurePurple) -
getADGroups()built theobjectGUIDstring in wire byte order whilegetUserADGroups()used LdapRecord'sGuidclass and its Windows mixed-endian layout. The identifiers stored by the admin mapping never matched the ones resolved at login, so no AD group could be mapped to a role β broken since 3.1.7.2, when the byte-order fix was applied to only one of the two call sites. Both conversions are now aligned onLdapRecord\Models\Attributes\Guid, the default GUID attribute isobjectguid(Active Directory has nogidNumber), nested memberships are resolved withLDAP_MATCHING_RULE_IN_CHAINwith a fallback to direct membership for directories without the extended matching rule, the user DN is escaped before entering a filter, and a failed membership lookup is reported as an error instead of being read as "no group", which used to strip every AD role from the user. - Nested groups now resolved in both login group check modes - Active Directory populates
memberOfwith direct membership only, soldap_allowed_login_group_mode = userdenied access to anyone inheriting the allowed group through a nested one, while the group-centric mode accepted them. The user-centric mode now falls back to ascope=baseread filtered on the reverse matching rule, only on the path that would otherwise deny access, a direct member still costs no extra query. No configuration change is required after the upgrade: the setting becomes a pure performance trade-off, and its tip has been updated accordingly (EN, FR). - API folder rights aligned with the web interface - folder access is resolved through the shared least-permissive-wins evaluator (a folder granted both R and W now yields R), and
ND/NE/NDNEare enforced on item update and delete. AD-sourced roles are taken into account, administrators get every shared folder, and explicitly forbidden folders are subtracted from the accessible list. Folder create/update also gained fixes:access_rightsdefaults toW, empty titles are rejected, the complexity level is validated on update, and both writes are wrapped in a transaction with the tree rebuild and cache refresh moved after the commit. - Folder password complexity exposed by the API -
GET /api/v1/folder/listFoldersandGET /api/v1/folder/writableFoldersnow return acomplexityfield (0|20|38|48|60), so a client such as the browser extension can generate a password that satisfies the folder's minimum strength before submitting it.0is returned for folders carrying no complexity rule, personal roots included. teampass-cli.shactually shipped - the Bash API client announced in 3.2.1.1 was swallowed by an unanchored*.shrule in.gitignoreand never reached the repository. It now lives in the released tree asapp/scripts/teampass-cli.sh, the documentation paths follow, and it is registered in both file-integrity manifests.- Web-root permission model clarified - the permissions documentation asked for every file to be owned by the web server user, which contradicted the "
app/andpublic/must not be writable" check: with0755andwww-dataas owner, the web server can still write. Both ownership models (simple and split-owner) are now documented, and the upgrade wizard's misleadingchmod 0755hint is replaced with an ownership-based fix that actually clears the warning.
π Bug fixes
- Legacy sharekey purge deleting the wrong rows - the
20231017_1upgrade operation and its runtime twin deletedsharekeys_files,sharekeys_fieldsandsharekeys_logsrows by item id, whileobject_idreferencesfiles.id,categories_items.idandlog_items.increment_idrespectively. The purge therefore missed its targets and could remove unrelated keys. All three statements now resolve the right object ids. - "Restore missing sharekeys" rebuilding keys for everyone on personal items - the tool excluded personal items on the
items.persoflag alone, so an item stored in a personal folder whose flag was still0had its keys rebuilt for every user. It now identifies personal items by their folder as well.
β¬οΈ Upgrade notes
upgrade_run_3.2.1.phpgains two one-shot data migrations, each guarded by its own marker so it never runs twice, and both idempotent. NoALTER TABLE, no schema change.- AD group identifier realignment - existing
ldap_groups_rolesrows are converted to the canonical GUID format. Only installs withldap_type = ActiveDirectoryusingobjectGUIDare touched; identifiers that are not canonical GUIDs are left untouched. - Personal sharekeys remediation - the foreign keys wrongly held on personal items are removed. The engine is the one behind
app/scripts/remediate_personal_sharekeys.php: it never deletes anything for an item whose owner is ambiguous. Running the script by hand is no longer necessary; it remains available with--dry-runfor admins who want to inspect first.
- AD group identifier realignment - existing
UPGRADE_MIN_DATEwas raised, so installations already running 3.2.1.0 or 3.2.1.1 are sent back through the upgrade wizard to pick both migrations up. This is expected, the upgrade is idempotent.- Active Directory users: check your group β role mappings after upgrading. The stored identifiers are converted in place, but the mapping never worked before this release, so it is worth confirming that each AD group now resolves to the intended role.
- Back up your database before upgrading, as always.
Full Changelog: 3.2.1.1...3.2.1.2
Important
- Requires at least
PHP 8.2
Languages
Please join Teampass v3 translation project on Poeditor and translate it for your language.
Installation
Follow instructions from Documentation.
Breaking Changes
- Minimum PHP version raised to 8.2
Security Fixes
- GHSA-66q9-mxf2-xqw6 β Missing authorization in `update_folder` action; folder moves now require caller access and reject crossβdomain (sharedβpersonal) transfers
- Personal item key generation no longer discloses other users' credentials; remediation migration removes stray sharekeys during upgrade
Weekly OSS security release digest.
The CVE patches and breaking changes that affected production tools this week. One email, every Sunday.
No spam, unsubscribe anytime.
Share this release
About Teampass
Password manager dedicated for managing passwords in a collaborative way. One symmetric key is used to encrypt all shared/team passwords and stored server side in a file and the database. works on any server Apache, MySQL and PHP.
Related context
Related tools
Earlier breaking changes
- v3.2.0.8 Enforces folderβlevel rights on bulk delete, move, and items_delete operations (#5275).
Beta — feedback welcome: [email protected]