Repository navigation
feat(AscHotPatch): interface hot-patch channel and 0x5BC formatter check (build-gated) - #14
Merged
Merged
Conversation
…eck (build-gated) Not in the original DLL; compiled only with ASCENSION_HOT_PATCH (OFF by default). - SMSG 0x8F0 runs server-sent interface Lua with guards: source only (no ESC byte, loadstring or string.dump), 32 KB per patch / 128 KB per session, run once per (patch id, content hash) per Lua session, per-realm consent (WTF\HotPatch.txt, /hotpatch on|ask|off), logged and listed by /hotpatch. An empty target runs at once with no taint source (as the formatter route does); a named target runs at that addon's ADDON_LOADED with its taint. - CMSG 0x8F1 announces the channel after world entry; CMSG 0x8F2 reports each patch's outcome. - SMSG 0x5BC rows are dropped unless every formatter is one return expression over value, literals and the seven functions the shipped table calls (AscDbcPatch validator hook). tests/hot_patch_formatter.py checks all 22 shipped formatters pass and 20 smuggling shapes are refused. Design: AscensionRebirth/HOT_PATCH_DESIGN.md. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
… to change it Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
- intro: Deliberate differences now cover the native logon and hot-patch build options and the tooltip insertion fix - reference regenerated: C_HotPatch bindings, SMSG 0x8F0 and CMSG 0x8F1/0x8F2 (named in the generator as ours), AscHotPatch module - AscHotPatch uses literal opcodes like the other modules so the generator lists them; AscDbcPatch header mentions SetValidator Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Not in the genuine DLL. Everything here is compiled in only with
-DASCENSION_HOT_PATCH=ON(OFF by default), so the exact reconstruction build is unchanged — the default build was rebuilt and contains none of it.Why
Servers already push interface Lua to the stock client: Fel Commutation (azerothcore-wotlk-coa #8021, DMCK96) and the Manastorm UI fixes (#8046) patch a
ChallengeRequirementTypesrow over SMSG0x5BCwhose formatter starts withend,, escaping the client'sreturn function(value) %s endtemplate, then fake a challenge 5 criteria completion to make the client compile it. No Ascension opcode is meant to carry interface code. This gives servers a supported channel for clients running this DLL, and closes the formatter route on it.Design and threat model:
AscensionRebirth/HOT_PATCH_DESIGN.md(not in this repo). In short: the server is open source, so payload signing would only protect one operator's players and is not used; the guards limit what a patch can reach rather than who may send one.What it does
0x8F0HOT_PATCH — sized patch id, sized target addon, sized Lua. Guards:loadstring, nostring.dump(this client'sloadstringalready refuses bytecode — measured in game — so this is a second layer);duplicate;issecurevariableon a pushed global (1 nil), so existing payloads behave the same on both routes;ADDON_LOADEDwith the addon's name as the taint source (0xD4139C), so it gets exactly the trust SMSG0x94Egave that addon;"applied"or"skipped: <reason>".0x8F1after every world entry (u32 protocol version 1, u8 mode) so the server can tell this DLL from the genuine one; CMSG0x8F2reports each patch's outcome (ran / applied / deferred / skipped / duplicate / refused-by-player / refused-guard / error, plus detail)./hotpatch offrefuses patches,/hotpatch askasks once per realm (StaticPopup naming the realm and patch ids),/hotpatch onallows again,/hotpatchlists the session's patches. Stored inWTF\HotPatch.txt.0x5BCcheck: a row is dropped unless every formatter is a singlereturn <expression>overvalue, literals, operators and the seven functions the shipped table calls (C_Quest.GetTitleByID,SecondsToTime,GetCreatureNameByID,GetMoneyString,C_Item.GetColoredItemName,GetColoredReputationName,GetFactionInfoByID). Implemented as a validator hook inAscDbcPatch(no-op unless a validator is registered).Opcodes
0x8F0–0x8F2come from an unused run inside the server's extension range, checked against the Ascension opcode list, the CoA server'sOpcodes.hand every opcode this DLL registers.Validation
tests/hot_patch_formatter.py: every formatter in the shippedChallengeRequirementTypes.dbc(22) passes; 20 smuggling shapes are refused. Passes under MSVC (x86) and g++.ASCENSION_HOT_PATCHon and off) compile and link; the off build contains none of the hot-patch strings.feat/coa-client-hot-patch, stacked on #8046):hot patch MANASTORM_UI_FIXES: ranandhot patch FEL_COMMUTATION_WINDOW: ran; both features behaved as on the formatter route;ran;.clientpush reqtype 25 PROBE …(the formatter escape) was refused by the0x5BCcheck: nothing ran and the token never registered./hotpatch offfollowed by a relog, Deny in ask mode, a patch with a named target addon.Server side
The matching server change (capability tracking, per-client route choice, result logging) will be a separate azerothcore-wotlk-coa PR once #8046 merges. Servers that don't know the opcodes are unaffected: the DLL only sends
0x8F1/0x8F2, which such servers ignore, and with the formatter route closed this build simply won't run their pushed Lua.🤖 Generated with Claude Code