3415 Commits
Author SHA1 Message Date
David Goodwin 199f498099 update changelog etc for 4.0.7 v4.0.7 postfixadmin-4.0.7 2026-11-18 11:17:15 +00:00
David Goodwin 07dd358d0e block XSS issues due to Smarty escape:quotes not escaping double quotes, block aliases without only one @ to be a route for XSS - thanks @mirko, CVE-2026-127178 2026-11-18 11:16:55 +00:00
David Goodwin 4ca45d5593 totp-exceptions -> default edit to 0 to avoid an undefined variable 2026-11-18 11:16:18 +00:00
David Goodwin 17930537de stop a domain admin from being able to enumerate all admin/superadmin usernames via list.php?table=adminpassword (thanks @cboltz & @mirko) 2026-11-18 09:57:34 +00:00
Christian Boltz e9dce61e5e Harden language catalog repair and syntax validation (#1114)
Improve language-update.sh script, fix missing semi-colons, cover languages/*.lang in ci with parallel-lint etc.
Fixes #1112 #1113

thanks @TrapoSAMA

Partially (only the language-update.sh changes) cherry-picked from 2008d06b
2026-11-17 00:18:52 +01:00
David Goodwin 2ae297dac8 update language-update.sh and get it to work again
(cherry picked from commit f96508af23)
2026-11-17 00:14:34 +01:00
David Goodwin ee7dced14d language-update.sh: token bug fixes (remove references to svn/sf.net, replace with github etc, remove svn info and use git log
(cherry picked from commit 6a45360d8c)
2026-11-17 00:14:23 +01:00
Christian Boltz 4696b8bb99 Add missing strings to all *.lang files 2026-11-16 22:55:20 +01:00
Christian Boltz 8d9cd2c603 en.lang: drop duplicate string pMenu_app_passwords 2026-11-16 22:53:56 +01:00
Rodrigo Cortés Cano d73e9768d0 fix: Mailbox users always see the hardcoded postbox icon even when an installation configures theme_logo. (#1195)
thanks @TrapoSAMA
2026-11-10 11:16:44 +00:00
Sven Strickroth 1ccefc1485 list-virtual_mailbox.tpl: Indicate by color whether vacation is active (#1192)
thanks @csware, see also #1193 (master)
2026-11-09 14:54:51 +00:00
Christian Boltz 3a2950ebb7 make dark-theme.css non-executable 2026-11-08 19:10:10 +01:00
David Goodwin 59ec8b4f2b github actions build: stop clobbering $PATH in install.sh; add composer validate --no-check-lock before install.sh v4.0.6 postfixadmin-4.0.6 2026-11-06 10:18:27 +00:00
David Goodwin c8b92047a6 Try and update CHANGELOG.TXT adding missing attributions/thanks etc, get ready for 4.0.6 release 2026-11-06 10:02:21 +00:00
Christian Boltz cc8285551c CHANGELOG: Add CVE number for TOTP exception description 2026-11-04 21:25:15 +01:00
Rodrigo Cortés Cano 0a894b0876 [4.x] Fix stored XSS in TOTP-exception and application-password lists (#1186)
Stored TOTP-exception and application-password descriptions bypass PFASmarty escaping on maintained 4.x, allowing mailbox-controlled markup to execute when a global administrator views the lists. Both controllers
now use the existing recursive HTML escaping so stored descriptions render as text, including records already in the database.

thanks @TrapoSAMA
2026-11-01 16:17:55 +00:00
Rodrigo Cortés Cano 40306e6ea7 Use concise Spanish Backup MX label consistently on 4.x (#1180)
see also #1171 and #1179 (master branch variant of this)

thanks @TrapoSAMA
2026-11-01 10:42:49 +00:00
David Goodwin b82f7184fb silently ignore searching on fields of type pass 2026-10-11 10:26:14 +01:00
David Goodwin 92fe42dd95 ensure sql injection is not possible with user supplied data being used as SQL column names in getPageBrowser - due to 2a6f27c3 / #1127
postfixadmin 4.0 does not pass user supplied keys as SQL column names, so is not vulnerable - this just provides a bit of defense in depth.

cherry picked from commit 317696013fe3a0c0b1135af0418f94d20599a5ef; test adjusted for 4.0's domain alias limit
2026-10-11 10:26:14 +01:00
Christian Boltz ba705d1a12 db_where_clause(): fix Exception message
... to mention the correct function name

(cherry picked from commit 047bf192fb)
2026-10-04 23:01:56 +02:00
Rodrigo Cortés Cano d3759ee6c8 Improve Spanish translations (#1171)
Update es.lang

thanks @TrapoSAMA
2026-10-04 09:56:32 +01:00
Rodrigo Cortés Cano 6c7146d2ea Distinguish local and external alias destinations on 4.x (#1168)
Port the final merged behavior of #1150 to `postfixadmin_4.0`, completing the wording-only port in #1152 (discussion #886).

Alias destinations with no matching local record within the administrator's managed domains are marked red; destinations outside those domains are marked blue without inspecting another administrator's
records. Mixed destinations can show both indicators. 

thanks @TrapoSAMA
2026-10-03 14:58:25 +01:00
Rodrigo Cortés Cano 0985ce9d90 Show configured TOTP status and reset action in 4.x (#1167)
After TOTP activation, the 4.x template hides the form with `visibility:hidden` but keeps its height, leaving the configured notice below a large empty area. 

See also #1166 (master), thanks @TrapoSAMA
2026-10-03 11:27:53 +01:00
David GoodwinandCopilot Autofix powered by AI ff41c7dece add space around "." (string concatenation)
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-09-29 12:05:32 +00:00
David Goodwin e16ed06976 fix from #1156, see also 3566e195c1 2026-09-29 12:05:32 +00:00
David Goodwin 54c130f2f0 fix from #1156 2026-09-29 12:05:32 +00:00
David Goodwin 2ee2504e56 should not need to pass in false here, as the init_session should have written mfa_complete to true etc 2026-09-29 12:05:32 +00:00
David Goodwin 77ccefdbf2 fix incomplete MFA logins having the ability to change state
when a user is part way through an MFA login (username/password auth done, but not the MFA bit),
authentication_get_username() will return their current username. This function is used in various other places
and historically it was a suitable check to determine if someone was also authenticated.

Commit updates authentication_get_username() to include a call to authentication_mfa_incomplete() by default, the only exclusion being on the login-mfa.php pages.

Thanks to Wenhao Wu (Southeast University) for the security report "MFA-incomplete (password-only) mailbox session can rewrite its own alias forwarding via /edit.php (CWE-308)"
2026-09-29 12:05:32 +00:00
David Goodwin 02305b0dd5 see #1162 - avoid passing null into explode(), thanks @danielsdadm-commits 2026-09-26 09:25:26 +01:00
Rodrigo Cortés Cano d1457da94f 4.x: improve alias destination status indicators (#1152)
Ports #1150 to `postfixadmin_4.0` and addresses discussion #886.

An alias destination absent from local records can be a valid external
address. Replace the misleading “maybe UNDELIVERABLE” label with
“Possible external destination” and add the short tooltip “Not listed as
a local destination.” English and Spanish wording matches #1150.

thanks @TrapoSAMA
2026-09-19 10:26:14 +01:00
Rodrigo Cortés Cano b5198b3ab3 4.x: require reauthentication for TOTP removal (#1135)
Require a completed authenticated role for TOTP management and verify the current password before removing a TOTP secret. 

See #1129 and #1128

thanks @TrapoSAMA
2026-09-16 15:00:47 +01:00
Rodrigo Cortés Cano bc80d14b76 4.x: scope Roundcube TOTP preference updates (#1139)
Limit the Roundcube preference update to the selected user and prevent serialized preferences from instantiating classes.

This ports PR #1133 with PHP 7.4 compatibility and validates the script arguments before accessing them.

Refs #1128

Thanks @TrapoAMA
2026-09-02 20:30:36 +01:00
Rodrigo Cortés Cano f29ac152fb 4.x: harden password recovery requests (#1136)
Require a validated canonical site_url for recovery links, keep responses uniform, and persist a five-minute per-account request limit.

This ports the behavior of PR #1130 while preserving PHP 7.4 compatibility and the 4.x database boolean handling.

Refs #1128

Thanks @TrapoSAMA
2026-09-02 20:29:26 +01:00
Rodrigo Cortés Cano f6a29e570c 4.x: enforce TOTP policy for XML-RPC login (#1137)
Reject password-only XML-RPC authentication for mailbox accounts that require TOTP while preserving existing behavior for accounts without TOTP.

This ports PR #1131 with PHP 7.4 compatibility and includes the documented XML-RPC/TOTP limitation requested during master review.

Refs #1128

thanks @TrapoSAMA
2026-09-02 20:17:45 +01:00
Rodrigo Cortés Cano 4a23d84ac4 4.x: enforce SMTP protocol state (#1138)
Improve SMTP (see smtp_mail()) - treat unexpected SMTP replies, incomplete writes, and failed TLS
negotiation as delivery failures. 

Refs #1128

thanks @TrapoSAMA
2026-09-02 20:15:54 +01:00
Rodrigo Cortés Cano b07850f2d6 4.x: escape viewlog output by default (#1140)
Restore default output sanitisation for viewlog records and replace the
inline JavaScript detail popup with native details markup.

This ports PR #1134 while preserving Smarty 3/4 and Bootstrap 3
compatibility.

Refs #1128

Thanks @TrapoSAMA
2026-09-02 20:09:20 +01:00
Rodrigo Cortés Cano 852e719183 4.x: fix legacy md5crypt compatibility (#1126)
- restore `md5crypt` as the PostfixAdmin 3.x-compatible alias for MD5-CRYPT
- verify stored unprefixed MD5-CRYPT, prefixed MD5-CRYPT, bcrypt, and SHA512 crypt hashes from their stored format
- document the canonical `MD5-CRYPT` setting, the legacy alias, and the 3.x upgrade implications

This addresses #1123 on `postfixadmin_4.0`. The `master` correction is in #1125 so each maintained branch can be reviewed and tested against its own PHP requirements.

thanks @TrapoSAMA
2026-08-29 15:11:10 +01:00
Rodrigo Cortés Cano e971465a5a pacrypt - be more tolerant of doveadm output (#1122)
- port the `doveadm pw` stderr and exit-status handling from #1121 to
`postfixadmin_4.0`
- preserve PHP 7.4-compatible syntax and the branch-specific password flow
- add the same portable regression coverage for password generation and verification

See #1119.

thanks @TrapoSAMA
2026-08-26 09:08:48 +01:00
Rodrigo Cortés Cano 564c47eaa3 Complete reviewed Spanish translations for 4.x (#1117)
Update Spanish translations.

thanks @TrapoSAMA
2026-08-14 10:15:03 +01:00
Rodrigo Cortés Cano 6e98667648 update languages/es.lang (#1115)
- add the missing Spanish translation for `pException_ip_error`, which is used by the 4.x TOTP exception flow
- remove the master-only `pDkim_field_domain_and_selector` key from the 4.x Spanish catalog
- restore exact key parity between `languages/en.lang` and `languages/es.lang`

related to  #1114 

thanks @TrapoSAMA
2026-08-12 09:08:40 +01:00
Rodrigo Cortés Cano 6e93d57766 Fix password expiration handling and visibility on 4.x (#1110)
- port the password-expiration correction to `postfixadmin_4.0`
- make password expiration optional and disabled by default
- make 0 consistently mean that domain passwords do not expire
- validate whole-day policies from 0 through 36500
- align password-change paths and preserve the existing Login fallback
- show mailbox expiration states in lists and CSV output
- add the new labels to every 4.x language file
- document how to enable the feature in `config.local.php`

thanks @TrapoSAMA
2026-08-11 09:28:19 +01:00
Rodrigo Cortés Cano 4ed71f0218 Improve TOTP code input semantics (#1106)
- identify TOTP inputs as one-time codes and request numeric keyboards
on supported devices
- keep TOTP digits visible while they are entered
- fix the TOTP input IDs so their labels point to the actual controls

thanks @TrapoSAMA
2026-08-10 09:09:58 +01:00
Rodrigo Cortés Cano 3769505e77 Clarify password expiration units on 4.x (#1108)
update the spanish and english password expiration translations to make it clear the units are in days.

thanks @TrapoSAMA
2026-08-09 09:09:37 +01:00
David Goodwin 604a298d6c update CHANGELOG.TXT 2026-08-03 21:22:29 +01:00
Rodrigo Cortés Cano 3bdb75b633 Distinguish mailbox and domain quota validation errors on 4.x (#1097)
- distinguish the per-mailbox maximum quota error from insufficient remaining domain quota
- add the domain-quota error message to every language catalog 
- add focused coverage for both quota failure causes

see also #1096 (same changes on master).
2026-08-03 21:01:24 +01:00
Rodrigo Cortés Cano 99caaab292 Drop obsolete password expiration SQL (#1099)
Delete password_expiration.sql - no longer needed (covered in existing db migration routines)

thanks @TrapoSAMA
2026-08-02 10:13:06 +01:00
Rodrigo Cortés Cano 75ae036fb8 Update Spanish translations on 4.x (#1101)
update languages/es.lang 

thanks @TrapoSAMA
2026-08-02 10:12:13 +01:00
Rodrigo Cortés Cano a1724aa59a Reconcile 3.3 MySQL upgrades on 4.x (#1088)
fix regression in MySQL schema upgrade from 3.3 where vacation.domain, vacation.email and quota2.username had the wrong collation. (Thanks @TrapoSAMA + @knofte)
2026-07-28 16:25:09 +01:00
Rodrigo Cortés Cano 26c56cf0e8 Keep 4.x login CSRF token stable across repeated GETs (#1087)
Do not recreate the CSRF token in the session if one already exists, this should avoid people seeing an expired CSRF token error
thanks @TrapoSAMA
2026-07-22 08:55:32 +01:00
Rodrigo Cortés Cano bfe0b8cfd0 Avoid restarting anonymous login sessions on 4.x (#1086)
Restrict recreating $_SESSION to only those where the user has been logged in previously; this should help stop anonymous users from failing a CSRF check.

thanks @TrapoSAMA
2026-07-22 08:51:38 +01:00