Add command line option /relax-order-checks

This commit is contained in:
Armin Novak 2018-10-17 12:15:57 +02:00
parent a432a297ca
commit 7b860ce96a
3 changed files with 17 additions and 6 deletions

View File

@ -1744,6 +1744,10 @@ int freerdp_client_settings_parse_command_line_arguments(rdpSettings* settings,
{
settings->ConsoleSession = TRUE;
}
CommandLineSwitchCase(arg, "relax-order-checks")
{
settings->AllowUnanouncedOrdersFromServer = arg->Value;
}
CommandLineSwitchCase(arg, "restricted-admin")
{
settings->ConsoleSession = TRUE;

View File

@ -142,6 +142,7 @@ static COMMAND_LINE_ARGUMENT_A args[] =
{ "pwidth", COMMAND_LINE_VALUE_REQUIRED, "<width>", NULL, NULL, -1, NULL, "Physical width of display (in millimeters)" },
{ "reconnect-cookie", COMMAND_LINE_VALUE_REQUIRED, "<base64-cookie>", NULL, NULL, -1, NULL, "Pass base64 reconnect cookie to the connection" },
{ "redirect-prefer", COMMAND_LINE_VALUE_REQUIRED, "<FQDN|IP|NETBIOS>[,<FQDN|IP|NETBIOS>[,<FQDN|IP|NETBIOS>]]", NULL, NULL, -1, NULL, "Override the preferred redirection order" },
{ "relax-order-checks", COMMAND_LINE_VALUE_FLAG, NULL, NULL, NULL, -1, "relax-order-checks", "Do not check if a RDP order was announced during capability exchange, only use when connecting to a buggy server" },
{ "restricted-admin", COMMAND_LINE_VALUE_FLAG, NULL, NULL, NULL, -1, "restrictedAdmin", "Restricted admin mode" },
{ "rfx", COMMAND_LINE_VALUE_FLAG, NULL, NULL, NULL, -1, NULL, "RemoteFX" },
{ "rfx-mode", COMMAND_LINE_VALUE_REQUIRED, "image|video", NULL, NULL, -1, NULL, "RemoteFX mode" },

View File

@ -121,13 +121,19 @@ static int check_order_activated(wLog* log, rdpSettings* settings, const char* o
{
if (!condition)
{
WLog_Print(log, WLOG_ERROR,
"%s - SERVER BUG: The support for this feature was not announced!", orderName);
if (!settings->AllowUnanouncedOrdersFromServer)
if (settings->AllowUnanouncedOrdersFromServer)
{
WLog_Print(log, WLOG_WARN,
"%s - SERVER BUG: The support for this feature was not announced!", orderName);
return 0;
}
else
{
WLog_Print(log, WLOG_ERROR,
"%s - SERVER BUG: The support for this feature was not announced! Use /relax-order-checks to ignore",
orderName);
return -1;
return 0;
}
}
return 1;