From 474d17d556d1f056b4055643a6a897483100dd7e Mon Sep 17 00:00:00 2001 From: Laxmikant Rashinkar Date: Sat, 3 Aug 2013 15:47:26 -0700 Subject: xrdp: added support for forcing credentials on command line --- libxrdp/xrdp_rdp.c | 4 ++++ libxrdp/xrdp_sec.c | 2 ++ 2 files changed, 6 insertions(+) (limited to 'libxrdp') diff --git a/libxrdp/xrdp_rdp.c b/libxrdp/xrdp_rdp.c index 82ccdea0..93219968 100644 --- a/libxrdp/xrdp_rdp.c +++ b/libxrdp/xrdp_rdp.c @@ -135,6 +135,10 @@ xrdp_rdp_read_config(struct xrdp_client_info *client_info) { client_info->pointer_flags = text2bool(value) == 0 ? 2 : 0; } + else if (g_strcasecmp(item, "require_credentials") == 0) + { + client_info->require_credentials = text2bool(value); + } } list_delete(items); diff --git a/libxrdp/xrdp_sec.c b/libxrdp/xrdp_sec.c index 54d5d0de..726fcde4 100644 --- a/libxrdp/xrdp_sec.c +++ b/libxrdp/xrdp_sec.c @@ -451,6 +451,8 @@ xrdp_sec_process_logon_info(struct xrdp_sec *self, struct stream *s) else { in_uint8s(s, len_password + 2); + if (self->rdp_layer->client_info.require_credentials) + return 1; /* credentials on cmd line is mandatory */ } unicode_in(s, len_program, self->rdp_layer->client_info.program, 255); -- cgit v1.2.1