[BUG] PTR Secure Template Problem Identified

by Cogwheel | 27/04/2007 23:52:32

Cogwheel

Well, one of them, anyway... Thanks to Foxlit of the EU.

It appears the very act of inheriting from SecureStateHeaderTemplate in XML causes some sort of taint when running addchild on any other header. Here is a simple example case (Note: simply removing the XML file from the .toc fixes the taint problem even though TaintTest_EvilFrame is not referenced anywhere in the lua file):

XML:

<Ui xmlns="http://www.blizzard.com/wow/ui/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.blizzard.com/wow/ui/">
<Frame name="TaintTest_EvilFrame" inherits="SecureStateHeaderTemplate"/>
</Ui>


Lua:


local Taint_Count = 0;
SLASH_TAINT1 = "/taint";
SlashCmdList["TAINT"] = function(msg)
Taint_Count = Taint_Count + 1;

local btn = CreateFrame("BUTTON","TTButton" .. Taint_Count, UIParent, "SecureActionButtonTemplate");
btn:SetAttribute("type", "target");
btn:SetAttribute("unit", "player");

if msg ~= "noparent" then
local hdr = CreateFrame("FRAME","TTHeader" .. Taint_Count, UIParent, "SecureStateHeaderTemplate");
hdr:SetAttribute("addchild", btn);
end

DEFAULT_CHAT_FRAME:AddMessage("[TaintTest] Type /click TTButton" .. Taint_Count .. "\n[TaintTest] Expected result: " .. (msg == "noparent" and "success" or "failure") .. ".");
end;

DEFAULT_CHAT_FRAME:AddMessage("[TaintTest] Try /taint and /taint noparent");


[ Post edited by Cogwheel ]


See my mods at http://cogwheel.wowinterface.com

I'd rather teach a man to fish.

http://www.catb.org/~esr/faqs/smart-questions.html#before

by Slouken | 01/05/2007 01:13:30

Slouken

I found some taint problems the week before last and fixed them for the next PTR update, and it looks like this was the same issue.

Thanks!

by Slouken | 01/05/2007 06:12:48

Slouken

I was out on vacation last week, but I think the test realm update that just went up has the fix. Can anyone verify?

Bump! Recently Bumped Threads

 

Blizzard Announcement Recent Blizzard Announcements

 

We suggest