FreeRDP
client/common/cmdline.c File Reference
#include <ctype.h>
#include <assert.h>
#include <errno.h>
#include <winpr/crt.h>
#include <winpr/wlog.h>
#include <winpr/path.h>
#include <freerdp/addin.h>
#include <freerdp/settings.h>
#include <freerdp/client/channels.h>
#include <freerdp/crypto/crypto.h>
#include <freerdp/locale/keyboard.h>
#include <freerdp/utils/passphrase.h>
#include <freerdp/channels/urbdrc.h>
#include <freerdp/client/cmdline.h>
#include <freerdp/version.h>
#include "compatibility.h"
#include "cmdline.h"
#include <freerdp/log.h>

Macros

#define TAG   CLIENT_TAG("common.cmdline")
 

Functions

static BOOL freerdp_client_print_codepages (const char *arg)
 
static BOOL freerdp_path_valid (const char *path, BOOL *special)
 
static BOOL freerdp_sanitize_drive_name (char *name, const char *invalid, const char *replacement)
 
static BOOL freerdp_client_add_drive (rdpSettings *settings, const char *path, const char *name)
 
static BOOL copy_value (const char *value, char **dst)
 
static BOOL append_value (const char *value, char **dst)
 
static BOOL value_to_int (const char *value, LONGLONG *result, LONGLONG min, LONGLONG max)
 
static BOOL value_to_uint (const char *value, ULONGLONG *result, ULONGLONG min, ULONGLONG max)
 
BOOL freerdp_client_print_version (void)
 
BOOL freerdp_client_print_buildconfig (void)
 
static char * print_token (char *text, size_t start_offset, size_t *current, size_t limit, const char delimiter)
 
static size_t print_optionals (const char *text, size_t start_offset, size_t current)
 
static size_t print_description (const char *text, size_t start_offset, size_t current)
 
static void freerdp_client_print_command_line_args (COMMAND_LINE_ARGUMENT_A *arg)
 
BOOL freerdp_client_print_command_line_help (int argc, char **argv)
 
BOOL freerdp_client_print_command_line_help_ex (int argc, char **argv, COMMAND_LINE_ARGUMENT_A *custom)
 
static int freerdp_client_command_line_pre_filter (void *context, int index, int argc, LPSTR *argv)
 
BOOL freerdp_client_add_device_channel (rdpSettings *settings, size_t count, char **params)
 
BOOL freerdp_client_add_static_channel (rdpSettings *settings, size_t count, char **params)
 
BOOL freerdp_client_add_dynamic_channel (rdpSettings *settings, size_t count, char **params)
 
static int freerdp_client_command_line_post_filter (void *context, COMMAND_LINE_ARGUMENT_A *arg)
 
BOOL freerdp_parse_username (const char *username, char **user, char **domain)
 
BOOL freerdp_parse_hostname (const char *hostname, char **host, int *port)
 
BOOL freerdp_set_connection_type (rdpSettings *settings, UINT32 type)
 
static int freerdp_map_keyboard_layout_name_to_id (char *name)
 
static int freerdp_detect_command_line_pre_filter (void *context, int index, int argc, LPSTR *argv)
 
static int freerdp_detect_windows_style_command_line_syntax (int argc, char **argv, size_t *count, BOOL ignoreUnknown)
 
static int freerdp_detect_posix_style_command_line_syntax (int argc, char **argv, size_t *count, BOOL ignoreUnknown)
 
static BOOL freerdp_client_detect_command_line (int argc, char **argv, DWORD *flags)
 
int freerdp_client_settings_command_line_status_print (rdpSettings *settings, int status, int argc, char **argv)
 
int freerdp_client_settings_command_line_status_print_ex (rdpSettings *settings, int status, int argc, char **argv, COMMAND_LINE_ARGUMENT_A *custom)
 
static BOOL ends_with (const char *str, const char *ext)
 
static void activate_smartcard_logon_rdp (rdpSettings *settings)
 
static BOOL parseSizeValue (const char *input, unsigned long *v1, unsigned long *v2)
 
int freerdp_client_settings_parse_command_line_arguments (rdpSettings *settings, int argc, char **argv, BOOL allowUnknown)
 
static BOOL freerdp_client_load_static_channel_addin (rdpChannels *channels, rdpSettings *settings, char *name, void *data)
 
BOOL freerdp_client_load_addins (rdpChannels *channels, rdpSettings *settings)
 

Macro Definition Documentation

#define TAG   CLIENT_TAG("common.cmdline")

FreeRDP: A Remote Desktop Protocol Implementation FreeRDP Client Command-Line Interface

Copyright 2012 Marc-Andre Moreau marca.nosp@m.ndre.nosp@m..more.nosp@m.au@g.nosp@m.mail..nosp@m.com Copyright 2014 Norbert Federa norbe.nosp@m.rt.f.nosp@m.edera.nosp@m.@thi.nosp@m.ncast.nosp@m..com Copyright 2016 Armin Novak armin.nosp@m..nov.nosp@m.ak@gm.nosp@m.ail..nosp@m.com

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Function Documentation

static void activate_smartcard_logon_rdp ( rdpSettings *  settings)
static

Here is the call graph for this function:

Here is the caller graph for this function:

static BOOL append_value ( const char *  value,
char **  dst 
)
static

Here is the caller graph for this function:

static BOOL copy_value ( const char *  value,
char **  dst 
)
static

Here is the call graph for this function:

Here is the caller graph for this function:

static BOOL ends_with ( const char *  str,
const char *  ext 
)
static

Here is the call graph for this function:

Here is the caller graph for this function:

BOOL freerdp_client_add_device_channel ( rdpSettings *  settings,
size_t  count,
char **  params 
)

Here is the call graph for this function:

Here is the caller graph for this function:

static BOOL freerdp_client_add_drive ( rdpSettings *  settings,
const char *  path,
const char *  name 
)
static

Here is the call graph for this function:

Here is the caller graph for this function:

BOOL freerdp_client_add_dynamic_channel ( rdpSettings *  settings,
size_t  count,
char **  params 
)

Here is the call graph for this function:

Here is the caller graph for this function:

BOOL freerdp_client_add_static_channel ( rdpSettings *  settings,
size_t  count,
char **  params 
)

Here is the call graph for this function:

Here is the caller graph for this function:

static int freerdp_client_command_line_post_filter ( void *  context,
COMMAND_LINE_ARGUMENT_A *  arg 
)
static

Here is the call graph for this function:

Here is the caller graph for this function:

static int freerdp_client_command_line_pre_filter ( void *  context,
int  index,
int  argc,
LPSTR *  argv 
)
static

Here is the call graph for this function:

Here is the caller graph for this function:

static BOOL freerdp_client_detect_command_line ( int  argc,
char **  argv,
DWORD *  flags 
)
static

Here is the call graph for this function:

Here is the caller graph for this function:

BOOL freerdp_client_load_addins ( rdpChannels *  channels,
rdpSettings *  settings 
)

Here is the call graph for this function:

Here is the caller graph for this function:

static BOOL freerdp_client_load_static_channel_addin ( rdpChannels *  channels,
rdpSettings *  settings,
char *  name,
void *  data 
)
static

Here is the call graph for this function:

Here is the caller graph for this function:

BOOL freerdp_client_print_buildconfig ( void  )

Here is the call graph for this function:

Here is the caller graph for this function:

static BOOL freerdp_client_print_codepages ( const char *  arg)
static

Here is the call graph for this function:

Here is the caller graph for this function:

static void freerdp_client_print_command_line_args ( COMMAND_LINE_ARGUMENT_A *  arg)
static

Here is the call graph for this function:

Here is the caller graph for this function:

BOOL freerdp_client_print_command_line_help ( int  argc,
char **  argv 
)

Here is the call graph for this function:

Here is the caller graph for this function:

BOOL freerdp_client_print_command_line_help_ex ( int  argc,
char **  argv,
COMMAND_LINE_ARGUMENT_A *  custom 
)

Here is the call graph for this function:

Here is the caller graph for this function:

BOOL freerdp_client_print_version ( void  )

Here is the caller graph for this function:

int freerdp_client_settings_command_line_status_print ( rdpSettings *  settings,
int  status,
int  argc,
char **  argv 
)

Here is the call graph for this function:

Here is the caller graph for this function:

int freerdp_client_settings_command_line_status_print_ex ( rdpSettings *  settings,
int  status,
int  argc,
char **  argv,
COMMAND_LINE_ARGUMENT_A *  custom 
)

Here is the call graph for this function:

Here is the caller graph for this function:

int freerdp_client_settings_parse_command_line_arguments ( rdpSettings *  settings,
int  argc,
char **  argv,
BOOL  allowUnknown 
)

FreeRDP: A Remote Desktop Protocol Implementation FreeRDP Client Command-Line Interface

Copyright 2012 Marc-Andre Moreau marca.nosp@m.ndre.nosp@m..more.nosp@m.au@g.nosp@m.mail..nosp@m.com

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Here is the call graph for this function:

Here is the caller graph for this function:

static int freerdp_detect_command_line_pre_filter ( void *  context,
int  index,
int  argc,
LPSTR *  argv 
)
static

Here is the call graph for this function:

Here is the caller graph for this function:

static int freerdp_detect_posix_style_command_line_syntax ( int  argc,
char **  argv,
size_t *  count,
BOOL  ignoreUnknown 
)
static

Here is the call graph for this function:

Here is the caller graph for this function:

static int freerdp_detect_windows_style_command_line_syntax ( int  argc,
char **  argv,
size_t *  count,
BOOL  ignoreUnknown 
)
static

Here is the call graph for this function:

Here is the caller graph for this function:

static int freerdp_map_keyboard_layout_name_to_id ( char *  name)
static

Here is the call graph for this function:

Here is the caller graph for this function:

BOOL freerdp_parse_hostname ( const char *  hostname,
char **  host,
int *  port 
)

Here is the call graph for this function:

Here is the caller graph for this function:

BOOL freerdp_parse_username ( const char *  username,
char **  user,
char **  domain 
)

Here is the call graph for this function:

Here is the caller graph for this function:

static BOOL freerdp_path_valid ( const char *  path,
BOOL *  special 
)
static

Here is the call graph for this function:

Here is the caller graph for this function:

static BOOL freerdp_sanitize_drive_name ( char *  name,
const char *  invalid,
const char *  replacement 
)
static

Here is the caller graph for this function:

BOOL freerdp_set_connection_type ( rdpSettings *  settings,
UINT32  type 
)

Here is the caller graph for this function:

static BOOL parseSizeValue ( const char *  input,
unsigned long *  v1,
unsigned long *  v2 
)
static

parses a string value with the format <v1>x<v2>

Parameters
inputinput string
v1pointer to output v1
v2pointer to output v2
Returns
if the parsing was successful

Here is the caller graph for this function:

static size_t print_description ( const char *  text,
size_t  start_offset,
size_t  current 
)
static

Here is the call graph for this function:

Here is the caller graph for this function:

static size_t print_optionals ( const char *  text,
size_t  start_offset,
size_t  current 
)
static

Here is the call graph for this function:

Here is the caller graph for this function:

static char* print_token ( char *  text,
size_t  start_offset,
size_t *  current,
size_t  limit,
const char  delimiter 
)
static

Here is the caller graph for this function:

static BOOL value_to_int ( const char *  value,
LONGLONG *  result,
LONGLONG  min,
LONGLONG  max 
)
static

Here is the caller graph for this function:

static BOOL value_to_uint ( const char *  value,
ULONGLONG *  result,
ULONGLONG  min,
ULONGLONG  max 
)
static

Here is the caller graph for this function: