24 #ifndef FREERDP_SETTINGS_TYPES_H
25 #define FREERDP_SETTINGS_TYPES_H
27 #include <winpr/timezone.h>
28 #include <winpr/wlog.h>
30 #include <freerdp/api.h>
31 #include <freerdp/config.h>
32 #include <freerdp/types.h>
33 #include <freerdp/redirection.h>
35 #include <freerdp/crypto/certificate.h>
36 #include <freerdp/crypto/privatekey.h>
48 #define SURFCMDS_SET_SURFACE_BITS 0x00000002
49 #define SURFCMDS_FRAME_MARKER 0x00000010
50 #define SURFCMDS_STREAM_SURFACE_BITS 0x00000040
53 #define RAIL_LEVEL_SUPPORTED 0x00000001
54 #define RAIL_LEVEL_DOCKED_LANGBAR_SUPPORTED 0x00000002
55 #define RAIL_LEVEL_SHELL_INTEGRATION_SUPPORTED 0x00000004
56 #define RAIL_LEVEL_LANGUAGE_IME_SYNC_SUPPORTED 0x00000008
57 #define RAIL_LEVEL_SERVER_TO_CLIENT_IME_SYNC_SUPPORTED 0x00000010
58 #define RAIL_LEVEL_HIDE_MINIMIZED_APPS_SUPPORTED 0x00000020
59 #define RAIL_LEVEL_WINDOW_CLOAKING_SUPPORTED 0x00000040
60 #define RAIL_LEVEL_HANDSHAKE_EX_SUPPORTED 0x00000080
63 #define PERF_FLAG_NONE 0x00000000
64 #define PERF_DISABLE_WALLPAPER 0x00000001
65 #define PERF_DISABLE_FULLWINDOWDRAG 0x00000002
66 #define PERF_DISABLE_MENUANIMATIONS 0x00000004
67 #define PERF_DISABLE_THEMING 0x00000008
68 #define PERF_DISABLE_CURSOR_SHADOW 0x00000020
69 #define PERF_DISABLE_CURSORSETTINGS 0x00000040
70 #define PERF_ENABLE_FONT_SMOOTHING 0x00000080
71 #define PERF_ENABLE_DESKTOP_COMPOSITION 0x00000100
74 #define CONNECTION_TYPE_INVALID \
79 #define CONNECTION_TYPE_MODEM 0x01
80 #define CONNECTION_TYPE_BROADBAND_LOW 0x02
81 #define CONNECTION_TYPE_SATELLITE 0x03
82 #define CONNECTION_TYPE_BROADBAND_HIGH 0x04
83 #define CONNECTION_TYPE_WAN 0x05
84 #define CONNECTION_TYPE_LAN 0x06
85 #define CONNECTION_TYPE_AUTODETECT 0x07
88 #define CS_CORE 0xC001
89 #define CS_SECURITY 0xC002
91 #define CS_CLUSTER 0xC004
92 #define CS_MONITOR 0xC005
93 #define CS_MCS_MSGCHANNEL 0xC006
94 #define CS_MONITOR_EX 0xC008
95 #define CS_UNUSED1 0xC00C
96 #define CS_MULTITRANSPORT 0xC00A
99 #define SC_CORE 0x0C01
100 #define SC_SECURITY 0x0C02
101 #define SC_NET 0x0C03
102 #define SC_MCS_MSGCHANNEL 0x0C04
103 #define SC_MULTITRANSPORT 0x0C08
111 RDP_VERSION_4 = 0x00080001,
112 RDP_VERSION_5_PLUS = 0x00080004,
113 RDP_VERSION_10_0 = 0x00080005,
114 RDP_VERSION_10_1 = 0x00080006,
115 RDP_VERSION_10_2 = 0x00080007,
116 RDP_VERSION_10_3 = 0x00080008,
117 RDP_VERSION_10_4 = 0x00080009,
118 RDP_VERSION_10_5 = 0x0008000a,
119 RDP_VERSION_10_6 = 0x0008000b,
120 RDP_VERSION_10_7 = 0x0008000C,
121 RDP_VERSION_10_8 = 0x0008000D,
122 RDP_VERSION_10_9 = 0x0008000E,
123 RDP_VERSION_10_10 = 0x0008000F,
124 RDP_VERSION_10_11 = 0x00080010,
125 RDP_VERSION_10_12 = 0x00080011
129 #define RNS_UD_COLOR_4BPP 0xCA00
130 #define RNS_UD_COLOR_8BPP 0xCA01
131 #define RNS_UD_COLOR_16BPP_555 0xCA02
132 #define RNS_UD_COLOR_16BPP_565 0xCA03
133 #define RNS_UD_COLOR_24BPP 0xCA04
136 #define RNS_UD_SAS_DEL 0xAA03
139 #define RNS_UD_24BPP_SUPPORT 0x0001
140 #define RNS_UD_16BPP_SUPPORT 0x0002
141 #define RNS_UD_15BPP_SUPPORT 0x0004
142 #define RNS_UD_32BPP_SUPPORT 0x0008
145 #define AUDIO_MODE_REDIRECT 0
146 #define AUDIO_MODE_PLAY_ON_SERVER 1
147 #define AUDIO_MODE_NONE 2
150 #define RNS_UD_CS_SUPPORT_ERRINFO_PDU 0x0001
151 #define RNS_UD_CS_WANT_32BPP_SESSION 0x0002
152 #define RNS_UD_CS_SUPPORT_STATUSINFO_PDU 0x0004
153 #define RNS_UD_CS_STRONG_ASYMMETRIC_KEYS 0x0008
154 #define RNS_UD_CS_RELATIVE_MOUSE_INPUT 0x0010
155 #define RNS_UD_CS_VALID_CONNECTION_TYPE 0x0020
156 #define RNS_UD_CS_SUPPORT_MONITOR_LAYOUT_PDU 0x0040
157 #define RNS_UD_CS_SUPPORT_NETCHAR_AUTODETECT 0x0080
158 #define RNS_UD_CS_SUPPORT_DYNVC_GFX_PROTOCOL 0x0100
159 #define RNS_UD_CS_SUPPORT_DYNAMIC_TIME_ZONE 0x0200
160 #define RNS_UD_CS_SUPPORT_HEARTBEAT_PDU 0x0400
161 #define RNS_UD_CS_SUPPORT_SKIP_CHANNELJOIN 0x0800
164 #define RNS_UD_SC_EDGE_ACTIONS_SUPPORTED_V1 0x00000001
165 #define RNS_UD_SC_DYNAMIC_DST_SUPPORTED 0x00000002
166 #define RNS_UD_SC_EDGE_ACTIONS_SUPPORTED_V2 0x00000004
167 #define RNS_UD_SC_SKIP_CHANNELJOIN_SUPPORTED 0x00000008
170 #define REDIRECTION_SUPPORTED 0x00000001
171 #define REDIRECTED_SESSIONID_FIELD_VALID 0x00000002
172 #define REDIRECTED_SMARTCARD 0x00000040
174 #define ServerSessionRedirectionVersionMask 0x0000003c
175 #define REDIRECTION_VERSION1 0x00
176 #define REDIRECTION_VERSION2 0x01
177 #define REDIRECTION_VERSION3 0x02
178 #define REDIRECTION_VERSION4 0x03
179 #define REDIRECTION_VERSION5 0x04
180 #define REDIRECTION_VERSION6 0x05
182 #define MONITOR_PRIMARY 0x00000001
185 #define ENCRYPTION_METHOD_NONE 0x00000000
186 #define ENCRYPTION_METHOD_40BIT 0x00000001
187 #define ENCRYPTION_METHOD_128BIT 0x00000002
188 #define ENCRYPTION_METHOD_56BIT 0x00000008
189 #define ENCRYPTION_METHOD_FIPS 0x00000010
192 #define ENCRYPTION_LEVEL_NONE 0x00000000
193 #define ENCRYPTION_LEVEL_LOW 0x00000001
194 #define ENCRYPTION_LEVEL_CLIENT_COMPATIBLE 0x00000002
195 #define ENCRYPTION_LEVEL_HIGH 0x00000003
196 #define ENCRYPTION_LEVEL_FIPS 0x00000004
199 #define TRANSPORT_TYPE_UDP_FECR 0x00000001
200 #define TRANSPORT_TYPE_UDP_FECL 0x00000004
201 #define TRANSPORT_TYPE_UDP_PREFERRED 0x00000100
202 #define SOFTSYNC_TCP_TO_UDP 0x00000200
205 #define CHANNEL_OPTION_INITIALIZED 0x80000000
206 #define CHANNEL_OPTION_ENCRYPT_RDP 0x40000000
207 #define CHANNEL_OPTION_ENCRYPT_SC 0x20000000
208 #define CHANNEL_OPTION_ENCRYPT_CS 0x10000000
209 #define CHANNEL_OPTION_PRI_HIGH 0x08000000
210 #define CHANNEL_OPTION_PRI_MED 0x04000000
211 #define CHANNEL_OPTION_PRI_LOW 0x02000000
212 #define CHANNEL_OPTION_COMPRESS_RDP 0x00800000
213 #define CHANNEL_OPTION_COMPRESS 0x00400000
214 #define CHANNEL_OPTION_SHOW_PROTOCOL 0x00200000
215 #define CHANNEL_REMOTE_CONTROL_PERSISTENT 0x00100000
218 #define VCCAPS_NO_COMPR 0x00000000
219 #define VCCAPS_COMPR_SC 0x00000001
220 #define VCCAPS_COMPR_CS_8K 0x00000002
223 #define LARGE_POINTER_FLAG_96x96 0x00000001
224 #define LARGE_POINTER_FLAG_384x384 0x00000002
227 #define AUTO_RECONNECT_VERSION_1 0x00000001
230 #define MSTSC_COOKIE_MAX_LENGTH 9
231 #define DEFAULT_COOKIE_MAX_LENGTH 0xFF
234 #define TS_CAPS_PROTOCOLVERSION 0x200
237 #define NEG_DSTBLT_INDEX 0x00
238 #define NEG_PATBLT_INDEX 0x01
239 #define NEG_SCRBLT_INDEX 0x02
240 #define NEG_MEMBLT_INDEX 0x03
241 #define NEG_MEM3BLT_INDEX 0x04
242 #define NEG_ATEXTOUT_INDEX 0x05
243 #define NEG_AEXTTEXTOUT_INDEX 0x06
244 #define NEG_DRAWNINEGRID_INDEX 0x07
245 #define NEG_LINETO_INDEX 0x08
246 #define NEG_MULTI_DRAWNINEGRID_INDEX 0x09
247 #define NEG_OPAQUE_RECT_INDEX 0x0A
248 #define NEG_SAVEBITMAP_INDEX 0x0B
249 #define NEG_WTEXTOUT_INDEX 0x0C
250 #define NEG_MEMBLT_V2_INDEX 0x0D
251 #define NEG_MEM3BLT_V2_INDEX 0x0E
252 #define NEG_MULTIDSTBLT_INDEX 0x0F
253 #define NEG_MULTIPATBLT_INDEX 0x10
254 #define NEG_MULTISCRBLT_INDEX 0x11
255 #define NEG_MULTIOPAQUERECT_INDEX 0x12
256 #define NEG_FAST_INDEX_INDEX 0x13
257 #define NEG_POLYGON_SC_INDEX 0x14
258 #define NEG_POLYGON_CB_INDEX 0x15
259 #define NEG_POLYLINE_INDEX 0x16
260 #define NEG_UNUSED23_INDEX 0x17
261 #define NEG_FAST_GLYPH_INDEX 0x18
262 #define NEG_ELLIPSE_SC_INDEX 0x19
263 #define NEG_ELLIPSE_CB_INDEX 0x1A
264 #define NEG_GLYPH_INDEX_INDEX 0x1B
265 #define NEG_GLYPH_WEXTTEXTOUT_INDEX 0x1C
266 #define NEG_GLYPH_WLONGTEXTOUT_INDEX 0x1D
267 #define NEG_GLYPH_WLONGEXTTEXTOUT_INDEX 0x1E
268 #define NEG_UNUSED31_INDEX 0x1F
271 #define GLYPH_SUPPORT_NONE 0x0000
272 #define GLYPH_SUPPORT_PARTIAL 0x0001
273 #define GLYPH_SUPPORT_FULL 0x0002
274 #define GLYPH_SUPPORT_ENCODE 0x0003
277 #define TSC_PROXY_MODE_NONE_DIRECT 0x0
278 #define TSC_PROXY_MODE_DIRECT 0x1
279 #define TSC_PROXY_MODE_DETECT 0x2
280 #define TSC_PROXY_MODE_DEFAULT 0x3
281 #define TSC_PROXY_MODE_NONE_DETECT 0x4
284 #define TSC_PROXY_CREDS_MODE_USERPASS 0x0
285 #define TSC_PROXY_CREDS_MODE_SMARTCARD 0x1
286 #define TSC_PROXY_CREDS_MODE_ANY 0x2
289 #define KEYBOARD_HOOK_LOCAL 0
290 #define KEYBOARD_HOOK_REMOTE 1
291 #define KEYBOARD_HOOK_FULLSCREEN_ONLY 2
300 #define LOGON_MSG_DISCONNECT_REFUSED 0xFFFFFFF9
301 #define LOGON_MSG_NO_PERMISSION 0xFFFFFFFA
302 #define LOGON_MSG_BUMP_OPTIONS 0xFFFFFFFB
303 #define LOGON_MSG_RECONNECT_OPTIONS 0xFFFFFFFC
304 #define LOGON_MSG_SESSION_TERMINATE 0xFFFFFFFD
305 #define LOGON_MSG_SESSION_CONTINUE 0xFFFFFFFE
307 #define LOGON_FAILED_BAD_PASSWORD 0x00000000
308 #define LOGON_FAILED_UPDATE_PASSWORD 0x00000001
309 #define LOGON_FAILED_OTHER 0x00000002
310 #define LOGON_WARNING 0x00000003
313 #define STATUS_FINDING_DESTINATION 0x00000401
314 #define STATUS_LOADING_DESTINATION 0x00000402
315 #define STATUS_BRINGING_SESSION_ONLINE 0x00000403
316 #define STATUS_REDIRECTING_TO_DESTINATION 0x00000404
317 #define STATUS_VM_LOADING 0x00000501
318 #define STATUS_VM_WAKING 0x00000502
319 #define STATUS_VM_BOOTING 0x00000503
322 #define PACKET_COMPR_TYPE_8K 0x00
323 #define PACKET_COMPR_TYPE_64K 0x01
324 #define PACKET_COMPR_TYPE_RDP6 0x02
325 #define PACKET_COMPR_TYPE_RDP61 0x03
326 #define PACKET_COMPR_TYPE_RDP8 0x04
329 #define ORIENTATION_LANDSCAPE 0
330 #define ORIENTATION_PORTRAIT 90
331 #define ORIENTATION_LANDSCAPE_FLIPPED 180
332 #define ORIENTATION_PORTRAIT_FLIPPED 270
335 #define CLIPRDR_FLAG_LOCAL_TO_REMOTE 0x01
336 #define CLIPRDR_FLAG_LOCAL_TO_REMOTE_FILES 0x02
337 #define CLIPRDR_FLAG_REMOTE_TO_LOCAL 0x10
338 #define CLIPRDR_FLAG_REMOTE_TO_LOCAL_FILES 0x20
340 #define CLIPRDR_FLAG_DEFAULT_MASK \
341 (CLIPRDR_FLAG_LOCAL_TO_REMOTE | CLIPRDR_FLAG_LOCAL_TO_REMOTE_FILES | \
342 CLIPRDR_FLAG_REMOTE_TO_LOCAL | CLIPRDR_FLAG_REMOTE_TO_LOCAL_FILES)
350 BYTE securityVerifier[16];
359 BYTE arcRandomBits[16];
397 UINT16 cacheMaximumCellSize;
413 UINT32 physicalWidth;
414 UINT32 physicalHeight;
416 UINT32 desktopScaleFactor;
417 UINT32 deviceScaleFactor;
432 #define RDPDR_DTYP_SERIAL 0x00000001
433 #define RDPDR_DTYP_PARALLEL 0x00000002
434 #define RDPDR_DTYP_PRINT 0x00000004
435 #define RDPDR_DTYP_FILESYSTEM 0x00000008
436 #define RDPDR_DTYP_SMARTCARD 0x00000020
478 #define PROXY_TYPE_NONE 0
479 #define PROXY_TYPE_HTTP 1
480 #define PROXY_TYPE_SOCKS 2
481 #define PROXY_TYPE_IGNORE 0xFFFF
484 #define THREADING_FLAGS_DISABLE_THREADS 0x00000001
486 enum rdp_settings_type
488 RDP_SETTINGS_TYPE_BOOL,
489 RDP_SETTINGS_TYPE_UINT16,
490 RDP_SETTINGS_TYPE_INT16,
491 RDP_SETTINGS_TYPE_UINT32,
492 RDP_SETTINGS_TYPE_INT32,
493 RDP_SETTINGS_TYPE_UINT64,
494 RDP_SETTINGS_TYPE_INT64,
495 RDP_SETTINGS_TYPE_STRING,
496 RDP_SETTINGS_TYPE_POINTER
502 #define FREERDP_SETTINGS_SERVER_MODE 0x00000001