Syntax error in my code.
Remove the { after the function set up.
I've edited my original post.
Still not guaranteed.
Edit - I also originally stated this would need to be in the server side lua run.
Now that I think about it, if the exploiter is running server side lua, then it would also need to be run on clients. So, both server and client.
Once the exploiter realized they couldn't have console spit out the convar, they could have whoever the host is do it.
-Host is on server. Uses Rcon_password to send commands
-Exploiter joins, tries to get rcon from server. (If my code worked), gets 'anti-hack' string.
-Exploiter realizes host might have convar set on game client.
- Exploiter runs server side code to force host client to say rcon_password.