Commit graph

160 commits

Author SHA1 Message Date
copilot-swe-agent[bot]
9550cd32b4
fix: billing order flow, steam_workshop lang key, workshop module install queries
- order.php: replace foreach((array)$mysqli_result) with proper fetch_assoc() loop
- order.php: fix hidden service_id field to use $_REQUEST instead of $_POST
- order.php: add safe error messages and error_log() on failed service lookup
- lang/English/global.php: add OGP_LANG_steam_workshop to fix _steam_workshop_ raw key
- steam_workshop/module.php: replace unusable $module_db_create heredoc with
  proper $install_queries[0] array so tables are created during module install
- timestamp.txt: updated

Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/70fa0082-93ad-4a4d-a1b3-ea6afa77ee80

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-04 17:15:07 +00:00
copilot-swe-agent[bot]
5c463d381f
fix: FAQ PHP warnings, billing nav, XML fatal-skip, Steam Workshop user menu
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/86bb1e0e-2bbd-439b-88cd-7a624ad24761

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-04 00:12:39 +00:00
copilot-swe-agent[bot]
9740cdd33b
fix: escape service_name in order.php to prevent XSS; modernize admin JS
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/28b4019a-734d-418e-8002-8c1ff0c0f564

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-03 23:04:59 +00:00
copilot-swe-agent[bot]
21bcdac9d7
fix: address review feedback - move JS to script block, use CSS classes
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/28b4019a-734d-418e-8002-8c1ff0c0f564

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-03 23:04:03 +00:00
copilot-swe-agent[bot]
70c3ff8979
fix: billing game images - dropdown selector, auto-guess, proper URL resolution
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/28b4019a-734d-418e-8002-8c1ff0c0f564

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-03 23:03:03 +00:00
copilot-swe-agent[bot]
a484974c06
fix: billing admin service list UI and customer server list display
- adminserverlist.php: fix th color (dark bg #2c3e50 + light text #f0f0f0)
  and add position:sticky to thead so header rows stay visible while scrolling
- adminserverlist.php: remove Out of Stock column from UI (thead, tbody),
  save handler (no longer reads/writes out_of_stock), and sync logic
  (soft-disable no longer sets out_of_stock = 1; new rows no longer insert it)
- adminserverlist.php: normalize price inputs to step=0.01 / 2 decimal places
- serverlist.php: fix foreach on mysqli_result cast bug that silently
  prevented all services from rendering; now uses fetch_assoc() loop
- serverlist.php: add IS NOT NULL guard alongside the != '' check

Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/3474562e-25f4-4d89-a030-f227e11b609b

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-03 22:39:49 +00:00
copilot-swe-agent[bot]
51e3bbe16d
fix: billing login fatal error (remove users_pass_hash UPDATE) and clean up DayZ Epoch XML post_install
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/ab0498eb-fc73-47ef-aec4-f20043320401

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-03 21:58:13 +00:00
copilot-swe-agent[bot]
ea995dc3b8
fix: sync billing_services from config_homes (one row per game), not config_mods
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/007e3cab-f414-4c90-864c-e820a847b637

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 21:28:46 +00:00
copilot-swe-agent[bot]
d57e3d0152
Fix: array offset on false in getNextAvailablePort, array-to-string in render_node attributes, missing columns in sync_billing_services INSERT
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/5bf3f57e-9174-4768-ae8b-c3526a1daeca

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 20:42:46 +00:00
copilot-swe-agent[bot]
ffece9ba57
fix: address code review nits - table name escaping, prefix fallback, gamemanager default, admin.php site vars
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/35af6b7c-2518-4105-b4d2-ba1f3fe754cd

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 19:43:35 +00:00
copilot-swe-agent[bot]
d8972fee16
fix: consolidate module schemas to db_version=1, fix billing admin undefined vars and prefix
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/35af6b7c-2518-4105-b4d2-ba1f3fe754cd

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 19:41:22 +00:00
copilot-swe-agent[bot]
744964ac60
fix: address code review nits - simplify array_map lambda and clarify empty remote_server_id
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/e8bfe531-e1ff-4257-b49c-f8376b84e772

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 15:42:09 +00:00
copilot-swe-agent[bot]
3024e41121
fix: config editor array-to-string warning and billing description INSERT failure
- config_servers.php: add gsp_normalize_config_value(), gsp_value_to_display_string(),
  gsp_value_to_editable_string() helpers; replace (string)$attrValue cast at line 124
  with gsp_value_to_editable_string() so PHP arrays from SimpleXML attribute iteration
  never trigger "Array to string conversion" notices
- adminserverlist.php sync_billing_services(): add description column (= service name)
  to INSERT so the query succeeds on databases where description is NOT NULL without
  a default; add pre-flight col_exists() schema guard that shows a friendly admin
  warning and aborts sync instead of crashing on completely missing columns

Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/e8bfe531-e1ff-4257-b49c-f8376b84e772

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 15:41:20 +00:00
copilot-swe-agent[bot]
8a832b0eac
fix: remove unused $type variable in adminserverlist.php flash loop
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/0b960e6d-bdf7-4b5b-8114-6c63e6b11a8d

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 15:22:58 +00:00
copilot-swe-agent[bot]
3219ed335e
fix: billing DB safety, remove mapping table, sync services from game config
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/0b960e6d-bdf7-4b5b-8114-6c63e6b11a8d

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 15:22:13 +00:00
copilot-swe-agent[bot]
61f6e517ec
fix: improve script-only install messaging and add error logging for exec() calls
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/9c87b62e-17b2-4f36-9b49-82238d73dda2

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 15:09:43 +00:00
copilot-swe-agent[bot]
75e63475ae
feat: remove legacy rsync/manual install methods, standardize SteamCMD pipeline, fix Update button
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/9c87b62e-17b2-4f36-9b49-82238d73dda2

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 15:08:38 +00:00
copilot-swe-agent[bot]
7f6fe9a39a
fix: address code review - prepared stmt, first-radio auto-select, remove unused var, clarify comment
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/4a9c8aab-3782-44a8-a5e4-01b50a813cc0

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 14:52:30 +00:00
copilot-swe-agent[bot]
b3d677035b
feat: update wording (GitHub Stable/Unstable) + billing matrix redesign
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/4a9c8aab-3782-44a8-a5e4-01b50a813cc0

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 14:50:25 +00:00
copilot-swe-agent[bot]
f4f222953f
fix: address code review feedback on billing admin fixes
- menu.php: remove unnecessary @ suppression from mysqli_thread_id()
  (instanceof check already guarantees a mysqli object)
- adminserverlist.php: split ternary flash message into separate if/else
  for readability; replace dynamic SQL fragment with explicit if/else
  query branches

Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/988997ed-7568-48bf-96ef-889fb5d91fec

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 13:41:13 +00:00
copilot-swe-agent[bot]
bb77620796
fix: resolve 3 billing admin errors and normalize remote_servers query
- admin_config.php: guard session_start() — was firing Notice because
  admin_auth.php → session_bridge.php already started the session
- includes/menu.php: check mysqli_thread_id() before reusing $db so a
  closed handle does not cause 'mysqli object is already closed' fatal
- admin_invoices.php / admin_payments.php: set $db = null after
  mysqli_close() so menu.php's reuse-check correctly falls through to
  opening a fresh connection
- adminserverlist.php: use col_exists() to detect missing 'enabled'
  column in gsp_remote_servers; fall back to constant 1 and display a
  schema-notice banner; guard UPDATE accordingly; also add missing
  price_daily / price_year columns to the services SELECT; remove
  duplicate 'Update Enabled Servers' button
- add_remote_server_enabled_column.sql: idempotent migration to add the
  'enabled' INT column to gsp_remote_servers on older installs

Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/988997ed-7568-48bf-96ef-889fb5d91fec

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 13:40:10 +00:00
copilot-swe-agent[bot]
fcc54cb2da
style: clean up string concatenation in config_loader.php
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/a3e1e4bb-8eb1-4e6e-b1f8-7f3952301231

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 13:16:40 +00:00
copilot-swe-agent[bot]
1247e5e7ca
fix: harden billing module for standalone portability
- config_loader.php: prefer local billing config FIRST (root cause fix)
  - was: panel config loaded first, overriding local config with wrong db name
  - now: local modules/billing/includes/config.inc.php always wins when present
- config.inc.php: add $db_port="3306"
- config.example.php: new example config with all variables documented
- menu.php: add $db_port to mysqli_connect
- admin_auth.php: add $db_port; remove hardcoded /_website path detection
- bootstrap.php billing_get_db(): add $db_port
- login.php: fix /_website path detection
- adminserverlist.php: add $db_port; fix hardcoded /modules/billing/ URL
- All other mysqli_connect calls: add isset($db_port) port parameter
  (my_servers, forgot_password, serverlist, server_status, order, register,
   reset_password, payment_success, my_account, admin_invoices, admin_payments,
   diag_remote, admin_coupons, test_db_connection, tools/check_db_user,
   renew_server)
- timestamp.txt: updated

Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/a3e1e4bb-8eb1-4e6e-b1f8-7f3952301231

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 13:15:50 +00:00
copilot-swe-agent[bot]
d4332808e6
chore: remove 22 stray backup files (.bak/.BAK/.orig/.backup); update CHANGELOG and timestamp
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/fe14a5ef-8993-48c4-a867-17971b58ac92

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 12:51:18 +00:00
copilot-swe-agent[bot]
3066d9c75c
fix(billing): address code review issues - ALTER TABLE syntax, null period handling, type detection
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/e8da2cb7-dbf1-4296-b25d-766f8e099581

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 12:23:23 +00:00
copilot-swe-agent[bot]
4a1b5bc725
fix(billing): address code review feedback
- Use DECIMAL instead of FLOAT for monetary columns in ALTER TABLE
- Simplify bind_param type string from concatenated to single literal
- Validate payment_status against ENUM values before CSS class injection
- Add provisioning failure logging when panel bootstrap fails
- Add comment explaining total_due/amount legacy fallback

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 12:19:32 +00:00
copilot-swe-agent[bot]
986a4e53b4
refactor(billing): clean architecture with payment gateway abstraction
- Add PaymentGatewayInterface contract for all payment providers
- Add PayPalGateway (reads credentials from config, not hardcoded)
- Add ManualGateway for admin-triggered payments
- Add StripeGateway stub for future implementation
- Add GatewayFactory for gateway instantiation by name
- Add BillingRepository: parameterized-SQL data layer
- Add BillingService: pricing, invoice creation, payment processing
- Add gsp_billing_transactions table (DB version 2) for audit trail
- Add new columns to gsp_billing_invoices (home_id, rate_type, players, period_start/end, subtotal, total_due, payment_status)
- Add gsp_billing_service_remote_servers mapping table
- Move PayPal credentials from api files into config.inc.php
- Fix double session_start() bug in capture_order.php
- Replace raw SQL with prepared statements throughout
- Refactor admin_invoices.php to use billing_invoices + BillingRepository
- Refactor admin_payments.php to read from gsp_billing_transactions
- Update admin.php with links to Transaction Log and Manage Invoices

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-02 12:17:36 +00:00
copilot-swe-agent[bot]
79d78f074b
fix: address code review comments (grace_days in Step B, simplified rate_map, spelling, comments)
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/5dbd58e1-7aa0-41e2-8dd3-c56b69ede05e

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-01 22:19:17 +00:00
copilot-swe-agent[bot]
b03d9b2171
feat: simplify billing status to Active/Invoiced/Expired with new SQL migration and cron rewrite
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/5dbd58e1-7aa0-41e2-8dd3-c56b69ede05e

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-01 22:17:22 +00:00
copilot-swe-agent[bot]
2d2fc496d5
fix: remove created_by_admin from billing INSERT and schema
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/2ce89b8b-fa50-40b9-aa38-4ebbc44a9770

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-01 13:52:38 +00:00
copilot-swe-agent[bot]
8a6823186a
fix: null handling in realEscapeSingle, init $map, add billing upgrade for created_by_admin
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/77c3c429-fc35-4f66-9d78-900be575b81a

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-01 13:16:04 +00:00
copilot-swe-agent[bot]
7551567354
fix: cast mod_name to string in preg_match; add created_by_admin to billing_orders schema
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/15c9652a-a4a6-4f02-bcc2-15f8fed708b1

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-05-01 13:04:31 +00:00
copilot-swe-agent[bot]
9d1999f374
feat: admin billing integration + migrate system (replaces clone)
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/8940e39d-4aaa-4154-874b-74ab24d74da3

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-04-30 20:54:08 +00:00
copilot-swe-agent[bot]
b8543dfbc5
feat: add GSP customized install.php with port support, auto-admin, and ogp_ migration
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/4b32e3c2-afec-458b-bf16-48e58045cc8b

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-04-27 19:57:03 +00:00
copilot-swe-agent[bot]
6c0ca40e09
Update timestamp and docs for PHP8 compatibility sweep
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/89922108-1604-44ae-949d-358d32b9d70a

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-04-23 14:04:13 +00:00
copilot-swe-agent[bot]
e44519c030
Apply automated PHP8 safety transforms
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/89922108-1604-44ae-949d-358d32b9d70a

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-04-23 14:01:37 +00:00
5b80f144e4 changed the server listing 2026-03-13 17:47:00 -04:00
copilot-swe-agent[bot]
d8ad1aa924 Fix workshop search appID lookup and checkbox picker
Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2026-01-31 19:01:46 +00:00
43f911dc93 fix menu 2025-12-06 07:15:45 -05:00
21696b36c5 fix 2025-12-05 15:27:13 -05:00
834ec56a4c fix login 2025-12-05 15:19:10 -05:00
28eb2671d5 fix login query 2025-12-05 15:16:12 -05:00
a70990359c fix login 2025-12-05 14:56:01 -05:00
bcc7d0ae2a login fix 2025-12-05 14:53:32 -05:00
baf92ab1ff edit login on website 2025-12-05 14:49:53 -05:00
5f5008b377 fixed missign config file and added check if xmlrpc istnt installed 2025-11-23 14:42:37 -05:00
copilot-swe-agent[bot]
ce70cc1256 Generate comprehensive documentation for all 149 games
- Fixed empty caption handling in XML parameter extraction
- Generated detailed startup parameters for all games from XML configs
- All games now have complete troubleshooting sections
- All navigation anchors working properly
- 149 games successfully processed with full documentation

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2025-11-22 23:12:17 +00:00
copilot-swe-agent[bot]
3e2fd5d620 Add XSS protection by escaping all HTML output
Escape all parameter keys, captions, descriptions, option values, and defaults before inserting into HTML to prevent XSS vulnerabilities from XML configuration data.

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2025-11-22 22:43:08 +00:00
copilot-swe-agent[bot]
293066cbfd Address code review feedback
- Fix option text handling to check for None instead of falsy
- Improve HTML cleaning with html.unescape and better tag removal
- Fix multi-line string in die() function
- Add html module import for proper HTML entity handling

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2025-11-22 22:40:38 +00:00
copilot-swe-agent[bot]
7fe56d207f Fix troubleshooting section anchor in generated docs
Move start script, service setup, and troubleshooting sections outside the conditional block to ensure they appear in all generated documentation regardless of whether detailed XML startup params exist.

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
2025-11-22 22:38:03 +00:00