Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
102 commits
Select commit Hold shift + click to select a range
92ffdb0
Cleanup of code and other improvements (#573)
luskaner Jul 20, 2026
42b9392
Added security checks for certificates so only those designed for age…
luskaner Jul 22, 2026
fde9707
Merge branch 'main' into 1.16.0
luskaner Jul 22, 2026
c91b461
Merge branch 'main' into 1.16.0
luskaner Jul 23, 2026
398c624
Merge branch 'main' into 1.16.0
luskaner Jul 24, 2026
7be23b4
Docker compose server and battle-server-manager now restart unless st…
luskaner Jul 24, 2026
856d1c7
Server and launcher no longer check battle server pid so it can work …
luskaner Jul 25, 2026
74ff878
Server gen-cert: Reverted mistake of not assigning KeyCertUsage to se…
luskaner Jul 27, 2026
ff8d72c
Merge branch 'main' into 1.16.0
luskaner Jul 29, 2026
d95262c
Server: add route /automatch2/getAutomatchMap for aoe4 (keep /automat…
luskaner Jul 30, 2026
8d20fb8
Server: Implement advertisement/getAdvertisementByPlatformSessionID a…
luskaner Aug 1, 2026
7f6fc70
Server: add stub for getChallengeProgressByProfileID for AoE4 (#587)
luskaner Aug 1, 2026
5d5843b
Server: disallow QM for aoe4 so further issues do not happen, includi…
luskaner Aug 4, 2026
fdec3b6
Fix dev task prepare-server replacing existing certificate
luskaner Aug 4, 2026
b2251d8
Fix .bat files
luskaner Aug 4, 2026
045c645
add config options Internet and ExternalIPAddress (#615)
bgstack15 Aug 17, 2026
6092263
Merge branch 'main' into 1.16.0
luskaner Aug 22, 2026
3ef4879
Update to go 1.27 and other improvements related (#617)
luskaner Aug 22, 2026
e80b9a3
Fix potential resource leaks and apply code inspection fixes
luskaner Aug 22, 2026
cbc48ff
Fix several common bugs and add its unit test suite
luskaner Aug 22, 2026
989aab1
Fix launcher-common bugs and add its unit test suite
luskaner Aug 22, 2026
3a855ed
Fix battle-server-broadcast bugs and add its unit test suite
luskaner Aug 22, 2026
927dadd
Fix battle-server-manager bugs and add its unit test suite
luskaner Aug 22, 2026
0d42dbe
Fix server-genCert bugs and add its unit test suite
luskaner Aug 22, 2026
97b7bdc
Fix server-docker compose and env configuration bugs
luskaner Aug 22, 2026
b1f1410
Revert env key lowercasing that broke capitalized configuration keys
luskaner Aug 22, 2026
fb7744e
Fix tools-scripts bugs and add its unit test suite
luskaner Aug 22, 2026
361a1ef
Fix tools-mock bugs and add unit tests
luskaner Aug 22, 2026
3017f52
Fix server-replay bugs and add its unit test suite
luskaner Aug 22, 2026
c2e2d99
Fix config-helper bugs and add its unit test suite
luskaner Aug 22, 2026
8bfdd35
Fix launcher-agent bugs and add its unit test suite
luskaner Aug 22, 2026
9e6093e
Fix launcher-config-admin logging bugs and add its unit test suite
luskaner Aug 23, 2026
c302c5a
Fix launcher-config-admin-agent bugs and add its unit test suite
luskaner Aug 23, 2026
c124935
Fix launcher-config bugs and add its unit test suite
luskaner Aug 23, 2026
68d254f
Fix launcher isolation profiles default key and enable its regression…
luskaner Aug 23, 2026
a3a1c8e
Fix launcher infinite loop on stdin EOF during server selection
luskaner Aug 23, 2026
8886942
Fix launcher macOS type assertion for native steam executor
luskaner Aug 23, 2026
f2f0a45
Fix launcher-agent typed-nil writer passed to child process
luskaner Aug 23, 2026
c815e79
Fix launcher UDP discovery race on shared sockets
luskaner Aug 23, 2026
e6d8715
Fix launcher resp.Body leak in ReadCACertificateFromServer
luskaner Aug 23, 2026
5d3041b
Fix launcher error overwriting when store and revert both fail
luskaner Aug 23, 2026
7eabeb8
Fix launcher data race on session state globals accessed from signal …
luskaner Aug 23, 2026
7ff5570
Fix mock tools log files opened without O_TRUNC
luskaner Aug 23, 2026
1b7a5e8
Fix launcher logger: prefix contamination, swallowed errors, case-sen…
luskaner Aug 23, 2026
73620ee
Fix Buffer failure overwriting exit codes set by operation closures
luskaner Aug 23, 2026
9ba7725
Fix launcher agent log file handle never closed in parent
luskaner Aug 23, 2026
4090448
Add launcher executor and broadcast coverage tests
luskaner Aug 23, 2026
db36bdb
Remove accidental coverage artifact from repo
luskaner Aug 23, 2026
afcf363
Fix gitignore: separate go.work.sum and add coverage pattern
luskaner Aug 23, 2026
8814b10
Fix server keyRWMutex TOCTOU race and CustomTime value receiver no-op
luskaner Aug 24, 2026
6848430
Fix server WSS, chat, auth, proxy, cookie and announcement bugs
luskaner Aug 24, 2026
a552bfa
Replace gorilla/websocket with lxzan/gws in server WSS handler
luskaner Aug 24, 2026
66c7487
Fix launcher-agent nil user permanently cached on generation failure
luskaner Aug 24, 2026
832edfe
Remove untestable WSS parseMessage valid-login test
luskaner Aug 24, 2026
0e863d9
Fix peerAdd rollback evicting pre-existing peers
luskaner Aug 24, 2026
735750d
Fix baseSession sweeper ticker panic on zero/negative interval
luskaner Aug 24, 2026
8e98b7e
Fix announce.go hot-spin on closed socket and log JoinGroup errors
luskaner Aug 24, 2026
17fe4c0
Add safe extraction helpers for auth middleware upstream responses
luskaner Aug 24, 2026
90e9233
Fix session message channel goroutine leaks and add session lifecycle…
luskaner Aug 24, 2026
3989bcc
Fix WSS reconnection loop: remove premature session deletion on disco…
luskaner Aug 24, 2026
64cbce4
Add Phase 1+2 test coverage and injectable-*With refactors for common…
luskaner Aug 24, 2026
6776631
Add test coverage for launcher-common pure-logic packages
luskaner Aug 24, 2026
d858d82
Add tests for server-genCert internal package
luskaner Aug 24, 2026
62e7b55
Add tests for battle-server-manager internal packages
luskaner Aug 24, 2026
04800c1
Add tests for mock/battle-server addToSlice
luskaner Aug 24, 2026
4612b7b
Add tests for scripts/goreleaser pure logic functions
luskaner Aug 24, 2026
04ae22d
Add tests for server-replay/http: cookies, delHeader, String()
luskaner Aug 24, 2026
82f2682
Add tests for server-replay/logEntry: CompareJSON, date validators, m…
luskaner Aug 24, 2026
43094ae
Fix 3 Taskfile bugs
luskaner Aug 24, 2026
dd4796c
Add tests for launcher-agent/gameLogs: Paths(), sortByModTime, error …
luskaner Aug 24, 2026
99d2ab6
Add tests for launcher-config-admin: cmd flag validation, error const…
luskaner Aug 24, 2026
5481e79
Add tests for launcher-config-admin-agent: checkCertificateValidity, …
luskaner Aug 24, 2026
23b7633
Add tests for launcher-config: error constants, NewCACert, cmd flag v…
luskaner Aug 24, 2026
4e8fade
Added more launcher tests
luskaner Aug 24, 2026
1820012
Add tests for common module: injectable error paths, integration tests
luskaner Aug 26, 2026
5c760cd
Improve tests and fix bugs for launcher-common and battle-server-broa…
luskaner Aug 26, 2026
99e2152
Improve tests and fix bugs for battle-server-manager
luskaner Aug 26, 2026
d4b5e2f
Improve tests and fix bugs for config-helper
luskaner Aug 26, 2026
83b1448
launcher: refactor runRoot with DI pattern and add comprehensive tests
luskaner Aug 27, 2026
b2e80b2
launcher-agent: fix 3 bugs, add DI injection, and comprehensive tests
luskaner Aug 27, 2026
9703e7d
test: improve coverage for launcher-config, launcher-config-admin, la…
luskaner Aug 28, 2026
e01c3bd
test: improve server coverage via DI and unit tests for utils, logger…
luskaner Aug 28, 2026
09860cb
test(server): exhaustive httptest coverage for all routes + robustnes…
luskaner Aug 28, 2026
1432489
refactor(launcher-common): convert revert/executor to injectable deps…
luskaner Sep 2, 2026
1a24efd
refactor(launcher-config-admin): convert admin client to injectable d…
luskaner Sep 2, 2026
3de8d48
test(server): add httptest/model/playfab/textmoderation/wss coverage
luskaner Sep 2, 2026
0bc0bfa
test(launcher): add cmdUtils root tests
luskaner Sep 2, 2026
dbd964f
chore: ignore coverage profiles and runtime-generated userData
luskaner Sep 2, 2026
d2d0fae
test: harden DI refactor against nil deps and brittle assertions
luskaner Sep 3, 2026
b83ed92
test: strengthen IPC tests with real assertions and goroutine sync
luskaner Sep 3, 2026
ca268aa
Update dependencies
luskaner Sep 10, 2026
26b6949
Merge
luskaner Sep 21, 2026
a543cc8
Merge 2
luskaner Sep 21, 2026
83af865
Fixed go.work
luskaner Sep 21, 2026
76a1b57
Fixed a merge issue
luskaner Sep 21, 2026
044b795
Renamed Internet to 'CanUseInternet'
luskaner Sep 21, 2026
d175e4c
Fix: canUseInternet not affecting server proxies
luskaner Sep 21, 2026
b39ac95
Fix: dev scripts and tasks
luskaner Sep 22, 2026
08eb997
Enhancement: added canUseInternet to launcher (and derived) too
luskaner Sep 22, 2026
2f1692d
Enhancement: moved to properties related to Internet
luskaner Sep 22, 2026
76cff1a
Merge branch 'main' into 1.16.0
luskaner Sep 22, 2026
7fe207a
Fix: launcher selectServerIndex not appearing
luskaner Sep 22, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
13 changes: 6 additions & 7 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,7 @@ jobs:
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version: '1.26.8'

go-version: '1.27.1'
- name: Initialize CodeQL
uses: github/codeql-action/init@v4
with:
Expand All @@ -48,11 +47,11 @@ jobs:
"./launcher-config-admin-agent|launcher/bin/config-admin-agent"
"./battle-server-manager|battle-server-manager/battle-server-manager"
"./tools/server-replay|tools/server-replay"
"./tools/scripts/cmd/copyBattleServerManagerResources.go|tools/scripts/copyBattleServerManagerResources"
"./tools/scripts/cmd/copyLauncherResources.go|tools/scripts/copyLauncherResources"
"./tools/scripts/cmd/copyServerResources.go|tools/scripts/copyServerResources"
"./tools/scripts/cmd/createServerResourcesFolder.go|tools/scripts/createServerResourcesFolder"
"./tools/scripts/cmd/generateGoreleaserConfig.go|tools/scripts/generateGoreleaserConfig"
"./tools/scripts/cmd/copyBattleServerManagerResources|tools/scripts/copyBattleServerManagerResources"
"./tools/scripts/cmd/copyLauncherResources|tools/scripts/copyLauncherResources"
"./tools/scripts/cmd/copyServerResources|tools/scripts/copyServerResources"
"./tools/scripts/cmd/createServerResourcesFolder|tools/scripts/createServerResourcesFolder"
"./tools/scripts/cmd/generateGoreleaserConfig|tools/scripts/generateGoreleaserConfig"
)
windows_targets=(
"./tools/mock/battle-server/main_windows.go|tools/battle-server"
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/releaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,14 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v6
with:
go-version: '1.26.8'
go-version: '1.27.1'
cache-dependency-path: |
go.work.sum
- name: Set up Go legacy
id: setup_go_legacy
run: |
dir="${{ vars.GOROOT_LEGACY }}"
version="1.26.8-1"
version="1.27.1-1"
subdir="go-legacy-win7"
curl -L https://github.com/thongtech/$subdir/releases/download/v$version/$subdir-$version.linux_amd64.tar.gz -o go.tar.gz
sudo mkdir -p "$dir"
Expand All @@ -36,7 +36,7 @@ jobs:
- name: Generate Goreleaser config
shell: bash
run: |
go run tools/scripts/cmd/generateGoreleaserConfig.go "${{ steps.setup_go_legacy.outputs.goroot }}"
go tool generateGoreleaserConfig "${{ steps.setup_go_legacy.outputs.goroot }}"
- name: Import GPG key
id: import_gpg
uses: crazy-max/ghaction-import-gpg@v7
Expand Down
8 changes: 6 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
.tools
.task
.env
.idea/
Expand All @@ -12,5 +11,10 @@ build/**/*
!build/battle-server-manager/
!build/battle-server-manager/.gitkeep
.goreleaser.yaml
.tools
tools/**/go.sum
go.work.sum
go.work.sum
coverage
cover_routes
coverage_all
userData/
26 changes: 22 additions & 4 deletions DEVELOPMENT.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
### System requirements

- OS requirements correspond to the server/launcher ones. Cross-compilation works on all systems out-the-box.
- Go 1.26:
- Go 1.27:
* Officially from https://go.dev/dl/ if not running Windows or is 10 and higher (or equivalent).
* Unofficially from either [thongtech/go-legacy-win7](https://github.com/thongtech/go-legacy-win7) or [XTLS/go-win7](https://github.com/XTLS/go-win7) if running Windows
7-8.X (or equivalent). Regardless if you install the official version, you need to install this one too for
Expand All @@ -18,6 +18,24 @@ Copy `.env.example` to `.env` and set:
* ```GOROOT_LEGACY``` to the legacy go installation path. Required for `task build` and
`task release`.

### Tools

Helper tools live in `tools/scripts/cmd` (one directory per tool) and are registered as `tool`
directives in `tools/scripts/go.mod`. There is no manual build step: `go` compiles and caches them
automatically.

Run any of them from the repository root:

```
go tool <name> [args]
```

Available tools: `copyBattleServerManagerResources`, `copyLauncherResources`, `copyServerResources`,
`createGameMockCA`, `createGameStructure`, `createServerResourcesFolder`, `generateGoreleaserConfig`.

List them with `go list tool`. They are normally invoked through `task`
(e.g. `task debug:prepare-server` or `task tools:run PROGRAM=createGameMockCA ARGS=age2`).

### Debug

It is recommended to use an IDE such as [GoLand](https://www.jetbrains.com/go/) (free for academia)
Expand All @@ -29,9 +47,9 @@ Depending on the module you want to debug, you will need to run the correspondin
- server: ```task debug:prepare-server```
- genCert: ```task debug:prepare-server-genCert```
- launcher: ```task debug:prepare-launcher```
- config: ```task debug:build-config-admin-agent```
- config-admin-agent: ```task debug:build-config-admin```
- agent: ```task debug:build-config-all```
- config: ```task debug:build-config```
- config-admin-agent: ```task debug:build-config-admin-agent```
- agent: ```task debug:build-launcher-agent```
- battle-server-manager: ```task debug:prepare-battle-server-manager```

### Build
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ system and configuration.
- Solaris-based (Solaris and Illumos).
- AIX.

Note: For the full list see [minimum requirements for Go](https://go.dev/wiki/MinimumRequirements) 1.26.
Note: For the full list see [minimum requirements for Go](https://go.dev/wiki/MinimumRequirements) 1.27.

</details>

Expand Down
4 changes: 1 addition & 3 deletions Taskfile.debug.unix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,9 @@ tasks:
prepare-launcher:
platforms: [ linux, darwin ]
internal: true
deps: [ ":build-server" ]
method: checksum
cmds:
- task: prepare-server
- task: build-config-helper-amd64
- task: build-config-helper-arm64
prepare-server:
platforms: [ linux ]
internal: true
Expand Down Expand Up @@ -37,6 +34,7 @@ tasks:
- config-helper/**/*
generates:
- build/launcher/bin/config-helper_{{.GOARCH}}.exe
- build/battle-server-manager/bin/config-helper_{{.GOARCH}}.exe
method: checksum
cmds:
- GOOS=windows GOARCH={{.GOARCH}} go build -o build/launcher/bin/config-helper_{{.GOARCH}}.exe ./config-helper
Expand Down
21 changes: 13 additions & 8 deletions Taskfile.debug.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,15 @@ tasks:
- build/server/resources/**/*
method: checksum
cmds:
- task: :tools:run
vars: { PROGRAM: 'createServerResourcesFolder' }
- task: :tools:run
vars: { PROGRAM: 'copyServerResources' }
prepare-server:
deps:
- prepare-server-genCert
- build-genCert
cmds:
- build/server/bin/genCert{{exeExt}} -r
ensure-certificate:
deps:
- prepare-server-genCert
- build-genCert
Expand All @@ -24,13 +28,14 @@ tasks:
- server-genCert/**/*
generates:
- build/server/bin/genCert{{exeExt}}
- build/server/resources/certificates/**/*
method: checksum
vars:
ARGS: '{{.ARGS | default ""}}'
cmds:
- build/server/bin/genCert{{exeExt}} -r
- build/server/bin/genCert{{exeExt}} -i {{.ARGS}}
prepare-launcher:
deps:
- build-config-all
- prepare-server
- prepare-battle-server-manager
- build-server
- build-launcher-agent
Expand All @@ -48,7 +53,7 @@ tasks:
- task: :tools:run
vars: { PROGRAM: 'copyLauncherResources' }
prepare-battle-server-manager:
deps: [ prepare-server ]
deps: [ ensure-certificate ]
sources:
- common/**/*
- battle-server-manager/**/*
Expand Down Expand Up @@ -78,7 +83,7 @@ tasks:
- build/server/bin/genCert{{exeExt}}
method: checksum
cmds:
- go build -o build/server/bin/genCert ./server-genCert
- go build -o build/server/bin/genCert{{exeExt}} ./server-genCert
build-battle-server-manager:
sources:
- common/**/*
Expand Down Expand Up @@ -132,6 +137,6 @@ tasks:
cmds:
- go build -o build/launcher/bin/config-admin-agent{{exeExt}} ./launcher-config-admin-agent
build-config-all:
deps: [ build-config, build-config-admin, build-config-admin-agent ]
deps: [ build-config, build-config-admin-agent ]
includes:
os: ./Taskfile.debug.{{if eq OS "windows"}}other{{else}}unix{{end}}.yml
16 changes: 1 addition & 15 deletions Taskfile.tools.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,8 @@
version: '3'

tasks:
build:
label: "Build {{.PROGRAM}}{{exeExt}}"
run: when_changed
internal: true
sources:
- tools/scripts/**/*
generates:
- .tools/{{.PROGRAM}}{{exeExt}}
method: checksum
cmds:
- go build -o ./.tools/{{.PROGRAM}}{{exeExt}} tools/scripts/cmd/{{.PROGRAM}}.go
run:
deps:
- task: build
vars: { PROGRAM: '{{.PROGRAM}}' }
cmds:
- ./.tools/{{.PROGRAM}}{{exeExt}} {{.ARGS | default ""}}
- go tool {{.PROGRAM}} {{.ARGS | default ""}}
includes:
mock: ./Taskfile.tools.mock.yml
4 changes: 2 additions & 2 deletions Taskfile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
# vim: set ts=2 sw=2 tw=0 fo=cnqoj
version: '3'

dotenv: [ '.env', '{{.ENV}}/.env.', '{{.HOME}}/.env' ]
dotenv: [ '.env', '{{.ENV}}/.env', '{{.HOME}}/.env' ]

tasks:
build-goreleaser-cfg:
internal: true
cmds:
- go run tools/scripts/cmd/generateGoreleaserConfig.go "{{ .GOROOT_LEGACY }}"
- go tool generateGoreleaserConfig "{{ .GOROOT_LEGACY }}"
build:
deps:
- build-goreleaser-cfg
Expand Down
Loading
Loading