Some small rest improvements. Use newest TServer binary.
This commit is contained in:
parent
dd05c524ec
commit
225668fcdd
4 changed files with 8 additions and 6 deletions
|
|
@ -300,8 +300,8 @@ namespace TShockAPI
|
||||||
return RestMissingParam("user");
|
return RestMissingParam("user");
|
||||||
|
|
||||||
var group = parameters["group"];
|
var group = parameters["group"];
|
||||||
if (string.IsNullOrWhiteSpace(group))
|
if (string.IsNullOrWhiteSpace(group))
|
||||||
return RestMissingParam("group");
|
group = TShock.Config.DefaultRegistrationGroupName;
|
||||||
|
|
||||||
var password = parameters["password"];
|
var password = parameters["password"];
|
||||||
if (string.IsNullOrWhiteSpace(password))
|
if (string.IsNullOrWhiteSpace(password))
|
||||||
|
|
|
||||||
|
|
@ -55,7 +55,7 @@ namespace Rests
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: Get rid of this when the old REST permission model is removed.
|
// TODO: Get rid of this when the old REST permission model is removed.
|
||||||
if (!TShock.Config.RestUseNewPermissionModel)
|
if (TShock.Config.RestApiEnabled && !TShock.Config.RestUseNewPermissionModel)
|
||||||
{
|
{
|
||||||
string warningMessage = string.Concat(
|
string warningMessage = string.Concat(
|
||||||
"You're using the old REST permission model which is highly vulnerable in matter of security. ",
|
"You're using the old REST permission model which is highly vulnerable in matter of security. ",
|
||||||
|
|
@ -67,7 +67,7 @@ namespace Rests
|
||||||
Console.WriteLine(warningMessage);
|
Console.WriteLine(warningMessage);
|
||||||
Console.ForegroundColor = ConsoleColor.Gray;
|
Console.ForegroundColor = ConsoleColor.Gray;
|
||||||
}
|
}
|
||||||
else
|
else if (TShock.Config.RestApiEnabled)
|
||||||
{
|
{
|
||||||
string warningMessage = string.Concat(
|
string warningMessage = string.Concat(
|
||||||
"You're using the new more secure REST permission model which can lead to compatibility problems ",
|
"You're using the new more secure REST permission model which can lead to compatibility problems ",
|
||||||
|
|
|
||||||
|
|
@ -76,7 +76,9 @@
|
||||||
<Reference Include="Microsoft.CSharp" />
|
<Reference Include="Microsoft.CSharp" />
|
||||||
<Reference Include="System.Data" />
|
<Reference Include="System.Data" />
|
||||||
<Reference Include="System.Xml" />
|
<Reference Include="System.Xml" />
|
||||||
<Reference Include="TerrariaServer">
|
<Reference Include="TerrariaServer, Version=0.0.0.0, Culture=neutral, processorArchitecture=x86">
|
||||||
|
<SpecificVersion>False</SpecificVersion>
|
||||||
|
<ExecutableExtension>.exe</ExecutableExtension>
|
||||||
<HintPath>..\TerrariaServerBins\TerrariaServer.exe</HintPath>
|
<HintPath>..\TerrariaServerBins\TerrariaServer.exe</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
@ -191,7 +193,7 @@
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ProjectExtensions>
|
<ProjectExtensions>
|
||||||
<VisualStudio>
|
<VisualStudio>
|
||||||
<UserProperties BuildVersion_IncrementBeforeBuild="False" BuildVersion_StartDate="2011/6/17" BuildVersion_BuildVersioningStyle="None.None.None.MonthAndDayStamp" BuildVersion_BuildAction="Both" BuildVersion_UpdateFileVersion="True" BuildVersion_UpdateAssemblyVersion="True" />
|
<UserProperties BuildVersion_UpdateAssemblyVersion="True" BuildVersion_UpdateFileVersion="True" BuildVersion_BuildAction="Both" BuildVersion_BuildVersioningStyle="None.None.None.MonthAndDayStamp" BuildVersion_StartDate="2011/6/17" BuildVersion_IncrementBeforeBuild="False" />
|
||||||
</VisualStudio>
|
</VisualStudio>
|
||||||
</ProjectExtensions>
|
</ProjectExtensions>
|
||||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||||
|
|
|
||||||
Binary file not shown.
Loading…
Add table
Add a link
Reference in a new issue