Fix Jexius's font exploit.
This commit is contained in:
parent
0b6777ba85
commit
1cd0f4c74b
5 changed files with 25 additions and 1 deletions
11
TShockAPI/Resources.Designer.cs
generated
11
TShockAPI/Resources.Designer.cs
generated
|
|
@ -1,7 +1,7 @@
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
// <auto-generated>
|
// <auto-generated>
|
||||||
// This code was generated by a tool.
|
// This code was generated by a tool.
|
||||||
// Runtime Version:4.0.30319.235
|
// Runtime Version:4.0.30319.1
|
||||||
//
|
//
|
||||||
// Changes to this file may cause incorrect behavior and will be lost if
|
// Changes to this file may cause incorrect behavior and will be lost if
|
||||||
// the code is regenerated.
|
// the code is regenerated.
|
||||||
|
|
@ -91,6 +91,15 @@ namespace TShockAPI {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Looks up a localized string similar to !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~
/// ¡¢£¤¥¦§¨©.
|
||||||
|
/// </summary>
|
||||||
|
internal static string mousefontchars {
|
||||||
|
get {
|
||||||
|
return ResourceManager.GetString("mousefontchars", resourceCulture);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Looks up a localized string similar to #format
|
/// Looks up a localized string similar to #format
|
||||||
///#ip group
|
///#ip group
|
||||||
|
|
|
||||||
|
|
@ -124,6 +124,9 @@
|
||||||
<data name="itembans" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
<data name="itembans" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||||
<value>config\itembans.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8</value>
|
<value>config\itembans.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="mousefontchars" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||||
|
<value>config\mousefontchars.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;utf-8</value>
|
||||||
|
</data>
|
||||||
<data name="users" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
<data name="users" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||||
<value>config\users.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;Windows-1252</value>
|
<value>config\users.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;Windows-1252</value>
|
||||||
</data>
|
</data>
|
||||||
|
|
|
||||||
|
|
@ -319,6 +319,16 @@ namespace TShockAPI
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
foreach (var character in text)
|
||||||
|
{
|
||||||
|
if (Resources.mousefontchars.IndexOf(character) == -1)
|
||||||
|
{
|
||||||
|
Tools.HandleCheater(tsplr, "Attempted to crash clients");
|
||||||
|
e.Handled = true;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (msg.whoAmI != ply)
|
if (msg.whoAmI != ply)
|
||||||
{
|
{
|
||||||
e.Handled = Tools.HandleGriefer(tsplr, "Faking Chat");
|
e.Handled = Tools.HandleGriefer(tsplr, "Faking Chat");
|
||||||
|
|
|
||||||
|
|
@ -135,6 +135,7 @@
|
||||||
</BootstrapperPackage>
|
</BootstrapperPackage>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<None Include="config\mousefontchars.txt" />
|
||||||
<Content Include="config\itembans.txt" />
|
<Content Include="config\itembans.txt" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
|
|
|
||||||
1
TShockAPI/config/mousefontchars.txt
Normal file
1
TShockAPI/config/mousefontchars.txt
Normal file
|
|
@ -0,0 +1 @@
|
||||||
|
!"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~
¡¢£¤¥¦§¨©
|
||||||
Loading…
Add table
Add a link
Reference in a new issue