Clemens Schwaighofer
44b825310a
Add ACL level number to unit detail
2025-02-07 19:06:35 +09:00
Clemens Schwaighofer
2c234ccef6
On config errors do not exit but throw exception
2025-01-29 09:57:58 +09:00
Clemens Schwaighofer
b493b3c4fd
Remove debug message
2025-01-20 20:27:34 +09:00
Clemens Schwaighofer
e7dd96b5d9
Further fixes for PHP 8.4
2025-01-20 20:27:03 +09:00
Clemens Schwaighofer
bcde36ac17
DB IO Cache reset should not be an error
...
If the query is not found, do not throw an error, just show a warning
2025-01-20 10:45:31 +09:00
Clemens Schwaighofer
8bde34ec7d
Fix bug in DB IO prepared statement with INSERT and auto RETURNING add
...
INSERT will get a RETURNING added automatically if it has a primary key
This was not checked when query was compared for prepared statements.
Also added a prepared statement status checker
2025-01-17 17:52:41 +09:00
Clemens Schwaighofer
a345d71306
De-depricate the ACL Login loginCheckEditAccessId method
...
This is still used a lot, and there is no reason to deprecate it so early.
First all the other logic should be brought in to make this an easy
conversion.
2025-01-17 14:43:13 +09:00
Clemens Schwaighofer
0ff6294faa
Fix ACL Login cuid <-> id pk lookups
...
Used the wrong SESSION var for lookup
2025-01-17 14:34:41 +09:00
Clemens Schwaighofer
757d7ae01d
ACL Login fixes for legacy id lookups
...
add an edit access id lookup to cuid
Fix unit_cuid not initialized, only old unit_id
2025-01-17 12:48:46 +09:00
Clemens Schwaighofer
4e78b21c67
phpstan fix for fegetcsv param $length
2025-01-17 09:59:39 +09:00
Clemens Schwaighofer
d7e6434808
New DeprecatedHelper namespace
...
For temporary wrapper functions for deprecated calls that need this
PHP 8.4 fputcsv/fgetcsv/str_getcsv encoding default change deprecated warning
Note this does not cover the SqlFileInfo class as this is not used in our code
2025-01-17 09:58:02 +09:00
Clemens Schwaighofer
443cc2751d
Update Logging file name change unit tests
2025-01-17 09:33:05 +09:00
Clemens Schwaighofer
cf6500b55a
Logging class change to "." for block separator
...
Blocks for info are now separated with "." and not "_" to make it visual more easy to see
2025-01-17 09:08:13 +09:00
Clemens Schwaighofer
09c2ec653f
ACL Login set deprecated edit user id too
...
We need that for some old calls in old projects
2025-01-16 14:49:15 +09:00
Clemens Schwaighofer
fc105f9295
Add ACL Login lookup edit access id to edit access cuid
2025-01-16 14:36:11 +09:00
Clemens Schwaighofer
053ab69330
Add edit access cuuid to the unit detail list
2025-01-16 14:04:30 +09:00
Clemens Schwaighofer
fd079316f5
ACL Login: Add edit_access_id to unit detail block
...
This is needed for a lot of legacy data lookup
2025-01-16 13:55:17 +09:00
Clemens Schwaighofer
08664e9834
Update log writing for login info
...
Fix the deprecated message in the Admin/Backend one with a full sample
Update the admin_header include sample page with the corret writeLog call
2025-01-16 10:40:41 +09:00
Clemens Schwaighofer
e063162161
Remove not needed use parts and ignore noop new for phan check
2025-01-15 12:53:02 +09:00
Clemens Schwaighofer
7fbc449a5c
PHPunit test call script update
...
Fix for default PHP set via getting version from default PHP.
Add a verbose option and remove the fixed verbose setting from the phpunit config
Update the options call to add a usage info block
2025-01-15 11:57:25 +09:00
Clemens Schwaighofer
72912c8c90
Bad password check for PHP earlier than 8.4
2025-01-06 13:52:28 +09:00
Clemens Schwaighofer
de2ed8be3d
EditBase SmartyExtended class call update
2024-12-27 17:07:44 +09:00
Clemens Schwaighofer
9d65f5d7c1
phpunit script update, SmartyExtended allow load of plugins
...
- phpunit has better options set for testdox/php version
- SmartyExtended has logger class as option (argument 2) and options
- SmartyExtneded can via option set html escape and load of plugins
- plugin array is set of
- file: path to plugin file
- type: what type this is
- tag: tag name
- callable: the callable for the tag name
- will throw exceptions on plugin load
- for all other things will set warning only and skip read
- fix the Smarty call with the logger option
- fix password test for PHP 8.4 password hash change
*IMPORTANT*
SmartyExtended($l10n, $logger, $cache_id, $compile_id)
The second argument is now the Logger class, this MUST be updated for all calls
2024-12-27 14:00:12 +09:00
Clemens Schwaighofer
fbe827e989
Update Smarty Extended for Smarty-extended v5 upgrade
2024-12-27 11:30:55 +09:00
Clemens Schwaighofer
c778a4eb81
Add phive back in for static tools like phpunit instead of using the composer package
2024-12-27 09:32:54 +09:00
Clemens Schwaighofer
ce1c72a0bc
Bug fix for DB IO parameters in CASE calls
2024-12-24 12:43:30 +09:00
Clemens Schwaighofer
10319ef728
Fix throws type for AsymmetricAnonymousEncryption in the phpdoc part
2024-12-23 12:56:57 +09:00
Clemens Schwaighofer
8d0036eaac
Fix phpdoc return types
2024-12-23 11:26:50 +09:00
Clemens Schwaighofer
d1e65c702e
Allow Seession settings to be changed
...
eg set the auto write + others
or set/unset can be chagned for single sets
2024-12-20 18:48:00 +09:00
Clemens Schwaighofer
7248906da7
Allow chaining of key set functions for encryption
2024-12-20 15:13:22 +09:00
Clemens Schwaighofer
7f9a4dc04f
Merge branch 'Feature-AsymmetricEncryption' into NewFeatures
2024-12-18 10:52:29 +09:00
Clemens Schwaighofer
10935214eb
Fix Class file name for asymmetric anonymous encryption
2024-12-18 10:50:27 +09:00
Clemens Schwaighofer
41e116f7d4
phpstan checks for level 9
2024-12-18 10:11:47 +09:00
Clemens Schwaighofer
881c93c343
Asymmetric Anoymouse Encryption phpunit tests
2024-12-18 09:56:48 +09:00
Clemens Schwaighofer
185d044a0b
Symmetric encryption key set tests
2024-12-17 18:23:10 +09:00
Clemens Schwaighofer
cc067cc202
Update symmetric encryption with compare/get key, empty key test, unset on end
...
All key and messages are set SensitiveParameter type
On end, unset the key parameter with sodium mem zero
Get/Compare key set methods
Additional check on empty key
Add missing sodium mem zero for inner function variable clean up
2024-12-17 15:18:06 +09:00
Clemens Schwaighofer
37e2e54b2a
Add asymmetric anonymous encryption
...
Private/Public key encryption for anonymous messages (not receipient)
2024-12-17 15:16:48 +09:00
Clemens Schwaighofer
711b3bfe97
Remove E_STRICT from error reporting, it is deprecated
2024-12-13 18:45:27 +09:00
Clemens Schwaighofer
3bd21c75d8
Make the font-size for ACL Login template a bit smaller
...
1.5em was too large, 1.3em is better
2024-12-13 13:58:56 +09:00
Clemens Schwaighofer
4971f62490
ecuid name fix in test file
2024-12-13 11:42:45 +09:00
Clemens Schwaighofer
1cf4fdf31a
Fix column named for edit_log to eu prefixed
...
as eucuid and eucuuid
2024-12-13 11:37:52 +09:00
Clemens Schwaighofer
d16b920966
Update arrayReturnMatchinKeyOnly description
2024-12-13 11:29:37 +09:00
Clemens Schwaighofer
ab52bf59b5
phan/phpstan fixes
2024-12-13 10:38:24 +09:00
Clemens Schwaighofer
a8dd076aac
Merge branch 'NewFeatures' into Feature-LoginClassAddUuidv4
2024-12-13 10:27:49 +09:00
Clemens Schwaighofer
c17ca1f847
Merge branch 'development'
2024-12-13 10:21:41 +09:00
Clemens Schwaighofer
e349613d60
phpunit updates
...
Add testsuits for default run
Fix wording in testdox
add a fallback in the Debugging Support test suit
2024-12-13 10:17:28 +09:00
Clemens Schwaighofer
e9cfdb4bf0
Remove all deprecated tests
2024-12-13 09:35:54 +09:00
Clemens Schwaighofer
f966209e0a
phpstan param declration fix for ACL Login user status
2024-12-12 21:20:09 +09:00
Clemens Schwaighofer
c13934de99
Fix for wrong key handling in Symmetric encryption
2024-12-12 21:09:41 +09:00
Clemens Schwaighofer
1e90bb677e
Fix Symmetric encryption with wrong key handling
...
- static call encrypt: do not check pre set key
- indirect call: set new if key is different
2024-12-12 21:07:17 +09:00
Clemens Schwaighofer
540269e61f
Fix update script for now to clock_timestamp
2024-12-12 19:04:21 +09:00
Clemens Schwaighofer
e793c3975b
Change all db now to clock_timestamp for triggers
2024-12-12 12:02:49 +09:00
Clemens Schwaighofer
7d4c9724fe
Fix session options argument declaration for phpstan
2024-12-11 21:10:00 +09:00
Clemens Schwaighofer
d1c4611431
Indent fix for ACL Login
2024-12-11 21:06:59 +09:00
Clemens Schwaighofer
8d3882a6fe
Session and ACL Login Class update
...
Session:
regenerate session id after some time or random.
Default is 'never', can be 'interval' form 0 to 1h and random from always to 1 in 100
Session also checks that strict session settings are enabled
Login class:
Automatic re-read of acl settings after some time (default 5min, can be chnaged via option).
Default set strict headers, can be turned off via option
Moved various parts into their own methods and cleaned up double call logic.
Login is now recorded in the last login entry
no more debug flags are read from the database anymore
All options are set via array and not with a single option (was auto login)
2024-12-11 21:05:56 +09:00
Clemens Schwaighofer
2b0434e36b
Merge branch 'NewFeatures' into Feature-AclLoginClassUpdateTokenCheckWithUuidV4
2024-12-11 10:36:57 +09:00
Clemens Schwaighofer
ba11a936db
DB IO remove debug placeholder output
2024-12-11 10:36:31 +09:00
Clemens Schwaighofer
df591659cb
Merge branch 'NewFeatures' into Feature-AclLoginClassUpdateTokenCheckWithUuidV4
2024-12-11 10:35:19 +09:00
Clemens Schwaighofer
5343034768
Fix DB IO placeholder detect and count regex
...
comment regex: (?:\-\-[^\r\n]*?\r?\n)*
Which is AFTER the element search as the comment can appear anywhere after the tag trigger
2024-12-11 10:30:41 +09:00
Clemens Schwaighofer
dec56c9559
Merge remote-tracking branch 'all/NewFeatures' into Feature-AclLoginClassUpdateTokenCheckWithUuidV4
2024-12-10 15:28:59 +09:00
Clemens Schwaighofer
880f15ac6f
Merge branch 'development'
2024-12-10 15:26:24 +09:00
Clemens Schwaighofer
a46601fe03
Sync folder is master and not trunk
2024-12-10 15:25:17 +09:00
Clemens Schwaighofer
022c39e791
Add missing phpunit test folder for deprecated session var load test
2024-12-10 15:24:45 +09:00
Clemens Schwaighofer
fdefaca301
Missing php unit test path for locale check
2024-12-10 15:22:59 +09:00
Clemens Schwaighofer
46e44c19bf
edit log table column order update
2024-12-10 14:44:42 +09:00
Clemens Schwaighofer
41cb6358f9
phpunit checks update, update edit_log logging sets
2024-12-10 14:40:07 +09:00
Clemens Schwaighofer
23142a4549
Merge branch 'Bug-DBIOWrongParamCountWithCommentBeforeParam' into Feature-AclLoginClassUpdateTokenCheckWithUuidV4
2024-12-10 13:37:43 +09:00
Clemens Schwaighofer
a7742bd5c8
DB IO count params fix for comments
2024-12-10 13:36:57 +09:00
Clemens Schwaighofer
50f83b822c
Merge branch 'Bug-DBIOWrongParamCountWithCommentBeforeParam' into Feature-AclLoginClassUpdateTokenCheckWithUuidV4
2024-12-10 12:02:31 +09:00
Clemens Schwaighofer
78591d6ba4
Fix Param regex lookup
...
Query was not counting params after "--" comment strings
2024-12-10 12:01:06 +09:00
Clemens Schwaighofer
e8299a123b
Update Edit Log with JSONB blocks
...
all action data goes into a JSON block and the old action columns will be deprecated
Same for ip, new ip address block with all possible ip addeses
Additional HTTP_ data goes into the http_data block
new request_schema column to get if the request was done to http or https
2024-12-10 10:06:49 +09:00
Clemens Schwaighofer
10c320f60c
Rename all ACL Login session vars to LOGIN_, remove debug enties
...
All ACL\Login loaded _SESSION vars are now prefixd with LOGIN_
only the language one stay as "DEFAULT_"
Removed DEBUG_ALL/DB_DEBUG as they are now fully removed from everywhere
- removed the edit user entries
- removed from the edit user table
The LANG direct loaded language entries is removed too. We only use locale and encoding.
No more LOCALE_PATH and DEFAULT_DOMAIN _SESSION are set during the option set
2024-12-09 19:37:23 +09:00
Clemens Schwaighofer
eeca138192
Remove the debug/db_debug flag from the edit user edit interface
...
These settings are deprecated and do nothing. keep the DB default values for now, but update table create to remove them.
They are set to 0
2024-12-09 19:22:54 +09:00
Clemens Schwaighofer
65715ea9c3
Add Array function to return only array entries based on matching key
...
A simple key based array filter
2024-12-09 19:13:03 +09:00
Clemens Schwaighofer
a56cbd8e97
ACL Login update layout to work with PC/Smartphone
...
Updated login template and password change template block
2024-12-09 16:20:21 +09:00
Clemens Schwaighofer
fe50a988a0
Switch session ACL Login user load check to cuuid
...
Update tests too for using edit user cuuid instead of the primary key
2024-12-06 20:11:28 +09:00
Clemens Schwaighofer
a84ab86e31
Various fixes for ACL Login methods with deprecated calls
...
make all calls that go through primary keys as deprecated
create CUID calls for all of them
Update phpunit tests with new cuid tests, keep old deprecated tests
2024-12-06 18:07:06 +09:00
Clemens Schwaighofer
b044999772
ACL Login query update to params and heredoc
...
All queries are in Params and all SQL is in heredoc blocks
Disable 1011 error entry, this is no longer used
2024-12-06 16:31:20 +09:00
Clemens Schwaighofer
98bf3a40cd
Add logout button to class.test.php for logout test, ANY placeholder db test
2024-12-06 14:54:09 +09:00
Clemens Schwaighofer
cbd47fb015
edit log table update, Change all DB tests serial to identity for primary key
2024-12-05 14:59:49 +09:00
Clemens Schwaighofer
5f89917abd
Add composer keywords
2024-12-05 14:30:12 +09:00
Clemens Schwaighofer
eeaff3042e
phpstan config file update with phpVersion information
2024-12-05 14:16:57 +09:00
Clemens Schwaighofer
d070c4e461
phan min php set to 8.2
2024-12-05 13:59:20 +09:00
Clemens Schwaighofer
e57c336dba
Clean up to use session methods and not _SESSION directly
...
Add session_unset for unsetAll and rename this method to "clear"
2024-12-05 13:52:45 +09:00
Clemens Schwaighofer
075fe967d5
Merge branch 'NewFeatures' into Feature-FixSessionClass
2024-12-05 12:18:51 +09:00
Clemens Schwaighofer
0e5f637052
Update Serial to Identity function
...
Return status as varchar from change.
clean up edit table SQL files with too many empty lines
2024-12-05 12:11:07 +09:00
Clemens Schwaighofer
2e1b767a85
Fix Session class with Many update and get
...
Update Login and Backend class to use interface when writing to avoid
problems with not written _SESSION vars with session is in write close status
2024-12-05 12:09:58 +09:00
Clemens Schwaighofer
f78c67c378
Fix ACL Login phpunit test
2024-12-04 14:17:16 +09:00
Clemens Schwaighofer
75e69932fc
Session class rewrite
...
create new session on class call, there is no need to delay that at all
new option to auto write close a session
session_id and session_name are stored as class vars
deprecate the __set/__get part because we do not want to set via ->session_var_name
but use the set()/get() methods.
They have been renamed from setS/getS... to set/get alone
2024-12-04 14:10:36 +09:00
Clemens Schwaighofer
7354632479
ACL Login update with cuuid and cuid add/update and move write log to login class
...
Add a UUIDv4 column to edit_generic as cuuid, add the cuid column to all reads with
the cuuid too
The cuuid will replace the cuid and remove the EUID as the session login var
Moved the adbEditLog to login class as writeLog and renamed the current private writeLog to writeEditLog which is only for internal logging in the class
The Backend log class is deprecated and a new get all action var method has been added to get the action vars into the edit log
2024-12-03 13:16:47 +09:00
Clemens Schwaighofer
5a21d22c7b
Add edit user cuid to session and ACL read
...
This is for phasing out the EUID and replace it with an UUIDv4 for any user settings
2024-12-02 17:09:02 +09:00
Clemens Schwaighofer
cee3b5c2d1
HSB Colorspace skip phpstan colorspace variable never read
2024-12-02 15:45:47 +09:00
Clemens Schwaighofer
47e44c15cc
Add a uuid4 validate method
2024-12-02 15:36:21 +09:00
Clemens Schwaighofer
83738adcb6
Remove old code
2024-11-27 14:32:34 +09:00
Clemens Schwaighofer
5454133239
Update SQL\PgSQL with param calls and heredoc, primary key search method update
...
The primary key currval select is udpated to use proper calls so it works with
serial and identity columns
2024-11-22 17:25:22 +09:00
Clemens Schwaighofer
87f35f23c3
edit_* table update for serial to identity columns
2024-11-22 17:24:34 +09:00
Clemens Schwaighofer
3c4c5d3106
Upgrade PostgreSQL serial to identity columns function
...
Function to help update PostgreSQL serial columns to identity
2024-11-22 17:21:07 +09:00
Clemens Schwaighofer
b080727ff3
Add missing PgSQL to the Interface
2024-11-21 10:40:24 +09:00
Clemens Schwaighofer
ae044bee6f
DB IO Placeholder convert fixers and updates
...
Add more checks in phpunit for this,
Update the placeholder check and convert and move all regex into the
placeholder convert support class
Move $ placeholder count function to the SQL\PgSQL class
Note: further moves of PgSQL only stuff have to be done for SQLite
SQL class add
2024-11-20 19:07:10 +09:00
Clemens Schwaighofer
529b6a75ba
Set base path for config file to load in edit_base.php
2024-11-19 15:43:00 +09:00