From 6882b1fa9d65a97915f3ec8953236539ed0b6656 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc-Andr=C3=A9=20Moreau?= Date: Wed, 31 Oct 2012 23:04:31 -0400 Subject: [PATCH] mfreerdp-server: initial commit --- channels/cliprdr/client/cliprdr_main.c | 2 +- channels/disk/client/disk_main.c | 2 +- channels/drdynvc/client/drdynvc_main.c | 2 +- channels/rail/client/rail_main.c | 2 +- channels/rdpdr/client/rdpdr_main.c | 2 +- channels/rdpsnd/client/rdpsnd_main.c | 2 +- channels/sample/client/sample_main.c | 2 +- channels/tsmf/client/tsmf_media.c | 2 +- client/Mac/MRDPRailView.h | 70 +++-- client/Mac/MRDPRailView.m | 5 +- client/X11/xfreerdp.c | 4 +- server/CMakeLists.txt | 6 +- server/Mac/CMakeLists.txt | 46 ++++ server/Mac/mf_audin.c | 75 +++++ server/Mac/mf_audin.h | 32 +++ server/Mac/mf_rdpsnd.c | 65 +++++ server/Mac/mf_rdpsnd.h | 32 +++ server/Mac/mfreerdp-server | Bin 0 -> 46364 bytes server/Mac/mfreerdp.c | 368 +++++++++++++++++++++++++ server/Mac/mfreerdp.h | 47 ++++ server/Mac/server.crt | 17 ++ server/Mac/server.key | 27 ++ 22 files changed, 760 insertions(+), 50 deletions(-) create mode 100644 server/Mac/CMakeLists.txt create mode 100644 server/Mac/mf_audin.c create mode 100644 server/Mac/mf_audin.h create mode 100644 server/Mac/mf_rdpsnd.c create mode 100644 server/Mac/mf_rdpsnd.h create mode 100755 server/Mac/mfreerdp-server create mode 100644 server/Mac/mfreerdp.c create mode 100644 server/Mac/mfreerdp.h create mode 100644 server/Mac/server.crt create mode 100644 server/Mac/server.key diff --git a/channels/cliprdr/client/cliprdr_main.c b/channels/cliprdr/client/cliprdr_main.c index b42338579..adb985546 100644 --- a/channels/cliprdr/client/cliprdr_main.c +++ b/channels/cliprdr/client/cliprdr_main.c @@ -274,7 +274,7 @@ static void cliprdr_process_terminate(rdpSvcPlugin* plugin) /* cliprdr is always built-in */ #define VirtualChannelEntry cliprdr_VirtualChannelEntry -const int VirtualChannelEntry(PCHANNEL_ENTRY_POINTS pEntryPoints) +int VirtualChannelEntry(PCHANNEL_ENTRY_POINTS pEntryPoints) { cliprdrPlugin* _p; diff --git a/channels/disk/client/disk_main.c b/channels/disk/client/disk_main.c index e721f67ae..0d75ab14f 100644 --- a/channels/disk/client/disk_main.c +++ b/channels/disk/client/disk_main.c @@ -697,7 +697,7 @@ void disk_register_disk_path(PDEVICE_SERVICE_ENTRY_POINTS pEntryPoints, char* na #define DeviceServiceEntry disk_DeviceServiceEntry #endif -const int DeviceServiceEntry(PDEVICE_SERVICE_ENTRY_POINTS pEntryPoints) +int DeviceServiceEntry(PDEVICE_SERVICE_ENTRY_POINTS pEntryPoints) { char* name; char* path; diff --git a/channels/drdynvc/client/drdynvc_main.c b/channels/drdynvc/client/drdynvc_main.c index 3f581159d..c4a189035 100644 --- a/channels/drdynvc/client/drdynvc_main.c +++ b/channels/drdynvc/client/drdynvc_main.c @@ -368,7 +368,7 @@ static void drdynvc_process_terminate(rdpSvcPlugin* plugin) /* drdynvc is always built-in */ #define VirtualChannelEntry drdynvc_VirtualChannelEntry -const int VirtualChannelEntry(PCHANNEL_ENTRY_POINTS pEntryPoints) +int VirtualChannelEntry(PCHANNEL_ENTRY_POINTS pEntryPoints) { drdynvcPlugin* _p; diff --git a/channels/rail/client/rail_main.c b/channels/rail/client/rail_main.c index aa9c85d2b..fdfaffc21 100644 --- a/channels/rail/client/rail_main.c +++ b/channels/rail/client/rail_main.c @@ -255,7 +255,7 @@ static void rail_process_event(rdpSvcPlugin* plugin, RDP_EVENT* event) /* rail is always built-in */ #define VirtualChannelEntry rail_VirtualChannelEntry -const int VirtualChannelEntry(PCHANNEL_ENTRY_POINTS pEntryPoints) +int VirtualChannelEntry(PCHANNEL_ENTRY_POINTS pEntryPoints) { railPlugin* _p; diff --git a/channels/rdpdr/client/rdpdr_main.c b/channels/rdpdr/client/rdpdr_main.c index 379555e3e..2ceabb0a5 100644 --- a/channels/rdpdr/client/rdpdr_main.c +++ b/channels/rdpdr/client/rdpdr_main.c @@ -319,7 +319,7 @@ static void rdpdr_process_terminate(rdpSvcPlugin* plugin) /* rdpdr is always built-in */ #define VirtualChannelEntry rdpdr_VirtualChannelEntry -const int VirtualChannelEntry(PCHANNEL_ENTRY_POINTS pEntryPoints) +int VirtualChannelEntry(PCHANNEL_ENTRY_POINTS pEntryPoints) { rdpdrPlugin* _p; diff --git a/channels/rdpsnd/client/rdpsnd_main.c b/channels/rdpsnd/client/rdpsnd_main.c index fd359c4e2..e6e833080 100644 --- a/channels/rdpsnd/client/rdpsnd_main.c +++ b/channels/rdpsnd/client/rdpsnd_main.c @@ -583,7 +583,7 @@ static void rdpsnd_process_terminate(rdpSvcPlugin* plugin) /* rdpsnd is always built-in */ #define VirtualChannelEntry rdpsnd_VirtualChannelEntry -const int VirtualChannelEntry(PCHANNEL_ENTRY_POINTS pEntryPoints) +int VirtualChannelEntry(PCHANNEL_ENTRY_POINTS pEntryPoints) { rdpsndPlugin* _p; diff --git a/channels/sample/client/sample_main.c b/channels/sample/client/sample_main.c index b9f2b3cc2..e94c33963 100644 --- a/channels/sample/client/sample_main.c +++ b/channels/sample/client/sample_main.c @@ -136,7 +136,7 @@ static void sample_process_terminate(rdpSvcPlugin* plugin) #define VirtualChannelEntry sample_VirtualChannelEntry -const int VirtualChannelEntry(PCHANNEL_ENTRY_POINTS pEntryPoints) +int VirtualChannelEntry(PCHANNEL_ENTRY_POINTS pEntryPoints) { samplePlugin* _p; diff --git a/channels/tsmf/client/tsmf_media.c b/channels/tsmf/client/tsmf_media.c index ab091de2c..3438e8a48 100644 --- a/channels/tsmf/client/tsmf_media.c +++ b/channels/tsmf/client/tsmf_media.c @@ -259,7 +259,7 @@ TSMF_PRESENTATION* tsmf_presentation_new(const BYTE* guid, IWTSVirtualChannelCal if (fout) { - fprintf(fout, "%d\n", (int) thid); + fprintf(fout, "%d\n", (int) (size_t) thid); fclose(fout); } diff --git a/client/Mac/MRDPRailView.h b/client/Mac/MRDPRailView.h index d33f4628b..0a6c56218 100644 --- a/client/Mac/MRDPRailView.h +++ b/client/Mac/MRDPRailView.h @@ -7,54 +7,52 @@ @interface MRDPRailView : NSView { - freerdp * rdp_instance; - rdpContext * context; - NSBitmapImageRep * bmiRep; - NSPoint savedDragLocation; - char * pixelData; - BOOL mouseInClientArea; - BOOL titleBarClicked; - BOOL gestureEventInProgress; - int width; - int height; - int savedWindowId; - int scrollWheelCount; + freerdp* rdp_instance; + rdpContext* context; + NSBitmapImageRep* bmiRep; + NSPoint savedDragLocation; + char* pixelData; + BOOL mouseInClientArea; + BOOL titleBarClicked; + BOOL gestureEventInProgress; + int width; + int height; + int savedWindowId; + int scrollWheelCount; - // store state info for some keys - int kdlshift; - int kdrshift; - int kdlctrl; - int kdrctrl; - int kdlalt; - int kdralt; - int kdlmeta; - int kdrmeta; - int kdcapslock; + /* store state info for some keys */ + int kdlshift; + int kdrshift; + int kdlctrl; + int kdrctrl; + int kdlalt; + int kdralt; + int kdlmeta; + int kdrmeta; + int kdcapslock; @public - BOOL isMoveSizeInProgress; - BOOL saveInitialDragLoc; - BOOL skipMoveWindowOnce; - int localMoveType; + BOOL isMoveSizeInProgress; + BOOL saveInitialDragLoc; + BOOL skipMoveWindowOnce; + int localMoveType; } -@property (assign) MRDPRailWindow * mrdpRailWindow; +@property (assign) MRDPRailWindow* mrdpRailWindow; @property (assign) int windowIndex; @property (assign) BOOL activateWindow; -- (void) windowDidMove:(NSNotification *) notification; +- (void) windowDidMove:(NSNotification*) notification; - (void) updateDisplay; -- (void) setRdpInstance:(freerdp *) instance width:(int) w andHeight:(int) h windowID:(int) windowID; -- (BOOL) eventIsInClientArea :(NSEvent *) event :(int *) xptr :(int *) yptr; +- (void) setRdpInstance:(freerdp*) instance width:(int) w andHeight:(int) h windowID:(int) windowID; - (void) setupBmiRep:(int) width :(int) height; - (void) releaseResources; -void mac_rail_MoveWindow(rdpRail *rail, rdpWindow *window); -void apple_to_windowMove(NSRect * r, RAIL_WINDOW_MOVE_ORDER * windowMove); -void mac_send_rail_client_event(rdpChannels *channels, UINT16 event_type, void *param); -void windows_to_apple_cords(NSRect * r); -void rail_MoveWindow(rdpRail * rail, rdpWindow * window); +void mac_rail_MoveWindow(rdpRail* rail, rdpWindow* window); +void apple_to_windowMove(NSRect* r, RAIL_WINDOW_MOVE_ORDER* windowMove); +void mac_send_rail_client_event(rdpChannels* channels, UINT16 event_type, void* param); +void windows_to_apple_cords(NSRect* r); +void rail_MoveWindow(rdpRail* rail, rdpWindow* window); void mac_rail_send_activate(int window_id); @end - diff --git a/client/Mac/MRDPRailView.m b/client/Mac/MRDPRailView.m index 16f6f66c1..c8510cc5e 100644 --- a/client/Mac/MRDPRailView.m +++ b/client/Mac/MRDPRailView.m @@ -106,7 +106,7 @@ extern struct kkey g_keys[]; } /** ********************************************************************* - * called when a mouse move event occurrs + * called when a mouse move event occurs * * ideally we want to be called when the mouse moves over NSView client area, * but in reality we get called any time the mouse moves anywhere on the screen; @@ -130,7 +130,7 @@ extern struct kkey g_keys[]; y = height - y; - // send mouse motion event to RDP server + /* send mouse motion event to RDP server */ rdp_instance->input->MouseEvent(rdp_instance->input, PTR_FLAGS_MOVE, x, y); } @@ -150,7 +150,6 @@ extern struct kkey g_keys[]; y = height - y; - if ((yPos >= 4) && (yPos <= 20)) titleBarClicked = YES; else diff --git a/client/X11/xfreerdp.c b/client/X11/xfreerdp.c index d84be57d6..785d020ae 100644 --- a/client/X11/xfreerdp.c +++ b/client/X11/xfreerdp.c @@ -1242,7 +1242,7 @@ int xfreerdp_run(freerdp* instance) int thid = 0; fscanf(fin, "%d", &thid); fclose(fin); - pthread_kill((pthread_t) thid, SIGUSR1); + pthread_kill((pthread_t) (size_t) thid, SIGUSR1); FILE *fin1 = fopen("/tmp/tsmf.tid", "rt"); int timeout = 5; @@ -1254,7 +1254,7 @@ int xfreerdp_run(freerdp* instance) if (timeout <= 0) { unlink("/tmp/tsmf.tid"); - pthread_kill((pthread_t) thid, SIGKILL); + pthread_kill((pthread_t) (size_t) thid, SIGKILL); break; } fin1 = fopen("/tmp/tsmf.tid", "rt"); diff --git a/server/CMakeLists.txt b/server/CMakeLists.txt index 7370bc2c9..741f98d4b 100644 --- a/server/CMakeLists.txt +++ b/server/CMakeLists.txt @@ -25,9 +25,13 @@ if(NOT WIN32) endif() find_suggested_package(X11) - if(WITH_X11) + if(WITH_X11 AND (NOT APPLE)) add_subdirectory(X11) endif() + + if(APPLE) + add_subdirectory(Mac) + endif() else() add_subdirectory(Windows) endif() diff --git a/server/Mac/CMakeLists.txt b/server/Mac/CMakeLists.txt new file mode 100644 index 000000000..7c50f16c8 --- /dev/null +++ b/server/Mac/CMakeLists.txt @@ -0,0 +1,46 @@ +# FreeRDP: A Remote Desktop Protocol Implementation +# FreeRDP Mac OS X Server cmake build script +# +# Copyright 2012 Marc-Andre Moreau +# +# 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. + +set(MODULE_NAME "mfreerdp-server") +set(MODULE_PREFIX "FREERDP_SERVER_MAC") + +set(${MODULE_PREFIX}_SRCS + mfreerdp.c + mfreerdp.h + mf_audin.c + mf_audin.h + mf_rdpsnd.c + mf_rdpsnd.h) + +add_executable(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS}) + +set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp-server) + +set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS + MONOLITHIC ${MONOLITHIC_BUILD} + MODULE freerdp + MODULES freerdp-core freerdp-utils freerdp-codec) + +set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS + MONOLITHIC ${MONOLITHIC_BUILD} + MODULE winpr + MODULES winpr-crt) + +target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS}) +install(TARGETS ${MODULE_NAME} DESTINATION ${CMAKE_INSTALL_BINDIR}) + +set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Server/Mac") diff --git a/server/Mac/mf_audin.c b/server/Mac/mf_audin.c new file mode 100644 index 000000000..7cd3d3631 --- /dev/null +++ b/server/Mac/mf_audin.c @@ -0,0 +1,75 @@ +/** + * FreeRDP: A Remote Desktop Protocol Implementation + * FreeRDP Mac OS X Server (Audio Input) + * + * Copyright 2012 Marc-Andre Moreau + * + * 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. + */ + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include "mfreerdp.h" + +#include "mf_audin.h" + +static const rdpsndFormat audio_formats[] = +{ + { 0x11, 2, 22050, 1024, 4, 0, NULL }, /* IMA ADPCM, 22050 Hz, 2 channels */ + { 0x11, 1, 22050, 512, 4, 0, NULL }, /* IMA ADPCM, 22050 Hz, 1 channels */ + { 0x01, 2, 22050, 4, 16, 0, NULL }, /* PCM, 22050 Hz, 2 channels, 16 bits */ + { 0x01, 1, 22050, 2, 16, 0, NULL }, /* PCM, 22050 Hz, 1 channels, 16 bits */ + { 0x01, 2, 44100, 4, 16, 0, NULL }, /* PCM, 44100 Hz, 2 channels, 16 bits */ + { 0x01, 1, 44100, 2, 16, 0, NULL }, /* PCM, 44100 Hz, 1 channels, 16 bits */ + { 0x01, 2, 11025, 4, 16, 0, NULL }, /* PCM, 11025 Hz, 2 channels, 16 bits */ + { 0x01, 1, 11025, 2, 16, 0, NULL }, /* PCM, 11025 Hz, 1 channels, 16 bits */ + { 0x01, 2, 8000, 4, 16, 0, NULL }, /* PCM, 8000 Hz, 2 channels, 16 bits */ + { 0x01, 1, 8000, 2, 16, 0, NULL } /* PCM, 8000 Hz, 1 channels, 16 bits */ +}; + +static void mf_peer_audin_opening(audin_server_context* context) +{ + printf("AUDIN opening.\n"); + /* Simply choose the first format supported by the client. */ + context->SelectFormat(context, 0); +} + +static void mf_peer_audin_open_result(audin_server_context* context, UINT32 result) +{ + printf("AUDIN open result %d.\n", result); +} + +static void mf_peer_audin_receive_samples(audin_server_context* context, const void* buf, int nframes) +{ + printf("AUDIN receive %d frames.\n", nframes); +} + +void mf_peer_audin_init(mfPeerContext* context) +{ + context->audin = audin_server_context_new(context->vcm); + context->audin->data = context; + + context->audin->server_formats = audio_formats; + context->audin->num_server_formats = sizeof(audio_formats) / sizeof(audio_formats[0]); + + context->audin->dst_format.wFormatTag = 1; + context->audin->dst_format.nChannels = 2; + context->audin->dst_format.nSamplesPerSec = 44100; + context->audin->dst_format.wBitsPerSample = 16; + + context->audin->Opening = mf_peer_audin_opening; + context->audin->OpenResult = mf_peer_audin_open_result; + context->audin->ReceiveSamples = mf_peer_audin_receive_samples; +} diff --git a/server/Mac/mf_audin.h b/server/Mac/mf_audin.h new file mode 100644 index 000000000..c5952f4af --- /dev/null +++ b/server/Mac/mf_audin.h @@ -0,0 +1,32 @@ +/** + * FreeRDP: A Remote Desktop Protocol Implementation + * FreeRDP Mac OS X Server (Audio Input) + * + * Copyright 2012 Marc-Andre Moreau + * + * 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. + */ + +#ifndef MF_AUDIN_H +#define MF_AUDIN_H + +#include +#include +#include + +#include "mfreerdp.h" + +void mf_peer_audin_init(mfPeerContext* context); + +#endif /* MF_AUDIN_H */ + diff --git a/server/Mac/mf_rdpsnd.c b/server/Mac/mf_rdpsnd.c new file mode 100644 index 000000000..a125771e2 --- /dev/null +++ b/server/Mac/mf_rdpsnd.c @@ -0,0 +1,65 @@ +/** + * FreeRDP: A Remote Desktop Protocol Implementation + * FreeRDP Mac OS X Server (Audio Output) + * + * Copyright 2012 Marc-Andre Moreau + * + * 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. + */ + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include + +#include "mf_rdpsnd.h" + +static const rdpsndFormat audio_formats[] = +{ + { 0x11, 2, 22050, 1024, 4, 0, NULL }, /* IMA ADPCM, 22050 Hz, 2 channels */ + { 0x11, 1, 22050, 512, 4, 0, NULL }, /* IMA ADPCM, 22050 Hz, 1 channels */ + { 0x01, 2, 22050, 4, 16, 0, NULL }, /* PCM, 22050 Hz, 2 channels, 16 bits */ + { 0x01, 1, 22050, 2, 16, 0, NULL }, /* PCM, 22050 Hz, 1 channels, 16 bits */ + { 0x01, 2, 44100, 4, 16, 0, NULL }, /* PCM, 44100 Hz, 2 channels, 16 bits */ + { 0x01, 1, 44100, 2, 16, 0, NULL }, /* PCM, 44100 Hz, 1 channels, 16 bits */ + { 0x01, 2, 11025, 4, 16, 0, NULL }, /* PCM, 11025 Hz, 2 channels, 16 bits */ + { 0x01, 1, 11025, 2, 16, 0, NULL }, /* PCM, 11025 Hz, 1 channels, 16 bits */ + { 0x01, 2, 8000, 4, 16, 0, NULL }, /* PCM, 8000 Hz, 2 channels, 16 bits */ + { 0x01, 1, 8000, 2, 16, 0, NULL } /* PCM, 8000 Hz, 1 channels, 16 bits */ +}; + +static void mf_peer_rdpsnd_activated(rdpsnd_server_context* context) +{ + printf("RDPSND Activated\n"); +} + +BOOL mf_peer_rdpsnd_init(mfPeerContext* context) +{ + context->rdpsnd = rdpsnd_server_context_new(context->vcm); + context->rdpsnd->data = context; + + context->rdpsnd->server_formats = audio_formats; + context->rdpsnd->num_server_formats = sizeof(audio_formats) / sizeof(audio_formats[0]); + + context->rdpsnd->src_format.wFormatTag = 1; + context->rdpsnd->src_format.nChannels = 2; + context->rdpsnd->src_format.nSamplesPerSec = 44100; + context->rdpsnd->src_format.wBitsPerSample = 16; + + context->rdpsnd->Activated = mf_peer_rdpsnd_activated; + + context->rdpsnd->Initialize(context->rdpsnd); + + return TRUE; +} diff --git a/server/Mac/mf_rdpsnd.h b/server/Mac/mf_rdpsnd.h new file mode 100644 index 000000000..5bd7d371d --- /dev/null +++ b/server/Mac/mf_rdpsnd.h @@ -0,0 +1,32 @@ +/** + * FreeRDP: A Remote Desktop Protocol Implementation + * FreeRDP Mac OS X Server (Audio Output) + * + * Copyright 2012 Marc-Andre Moreau + * + * 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. + */ + +#ifndef MF_RDPSND_H +#define MF_RDPSND_H + +#include +#include +#include + +#include "mfreerdp.h" + +BOOL mf_peer_rdpsnd_init(mfPeerContext* context); + +#endif /* MF_RDPSND_H */ + diff --git a/server/Mac/mfreerdp-server b/server/Mac/mfreerdp-server new file mode 100755 index 0000000000000000000000000000000000000000..e0e450da6d032a375758a92e2a50564ebd6f5d77 GIT binary patch literal 46364 z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yv?ZmUNh}hH4HPE#AQ|MtK6WhX}S?t?g<3DT|?_Jdr~Gw6iWq*PeZQk zlrV=*0c?y!q}Pm!BT~a+iNw-j)B?dETMQ*WWTw$O_)I$39l&&e0ODfl&IskqZ7h~# yxYre~Q!-5j4+0vbQ)l`J_-$m(NJX&fqo~su0&cUj*8ssV&!A($9()4j>Hh$HmLu%| literal 0 HcmV?d00001 diff --git a/server/Mac/mfreerdp.c b/server/Mac/mfreerdp.c new file mode 100644 index 000000000..f77647970 --- /dev/null +++ b/server/Mac/mfreerdp.c @@ -0,0 +1,368 @@ +/** + * FreeRDP: A Remote Desktop Protocol Implementation + * FreeRDP Mac OS X Server + * + * Copyright 2012 Marc-Andre Moreau + * + * 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. + */ + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include +#include +#include +#include +#include +#include +#include + +#include + +#include +#include +#include +#include + +#include "mf_audin.h" +#include "mf_rdpsnd.h" + +#include "mfreerdp.h" + +void mf_peer_context_new(freerdp_peer* client, mfPeerContext* context) +{ + context->rfx_context = rfx_context_new(); + context->rfx_context->mode = RLGR3; + context->rfx_context->width = client->settings->width; + context->rfx_context->height = client->settings->height; + rfx_context_set_pixel_format(context->rfx_context, RDP_PIXEL_FORMAT_R8G8B8); + + context->nsc_context = nsc_context_new(); + nsc_context_set_pixel_format(context->nsc_context, RDP_PIXEL_FORMAT_R8G8B8); + + context->s = stream_new(0xFFFF); + + context->vcm = WTSCreateVirtualChannelManager(client); +} + +void mf_peer_context_free(freerdp_peer* client, mfPeerContext* context) +{ + if (context) + { + stream_free(context->s); + + rfx_context_free(context->rfx_context); + nsc_context_free(context->nsc_context); + + if (context->audin) + audin_server_context_free(context->audin); + + if (context->rdpsnd) + rdpsnd_server_context_free(context->rdpsnd); + + WTSDestroyVirtualChannelManager(context->vcm); + } +} + +static void mf_peer_init(freerdp_peer* client) +{ + client->context_size = sizeof(mfPeerContext); + client->ContextNew = (psPeerContextNew) mf_peer_context_new; + client->ContextFree = (psPeerContextFree) mf_peer_context_free; + freerdp_peer_context_new(client); +} + +BOOL mf_peer_post_connect(freerdp_peer* client) +{ + int i; + mfPeerContext* context = (mfPeerContext*) client->context; + + printf("Client %s is activated\n", client->hostname); + + if (client->settings->autologon) + { + printf(" and wants to login automatically as %s\\%s", + client->settings->domain ? client->settings->domain : "", + client->settings->username); + + /* A real server may perform OS login here if NLA is not executed previously. */ + } + printf("\n"); + + printf("Client requested desktop: %dx%dx%d\n", + client->settings->width, client->settings->height, client->settings->color_depth); + + /* Iterate all channel names requested by the client and activate those supported by the server */ + + for (i = 0; i < client->settings->num_channels; i++) + { + if (client->settings->channels[i].joined) + { + if (strncmp(client->settings->channels[i].name, "rdpsnd", 6) == 0) + { + mf_peer_rdpsnd_init(context); /* Audio Output */ + } + } + } + + /* Dynamic Virtual Channels */ + + mf_peer_audin_init(context); /* Audio Input */ + + return TRUE; +} + +BOOL mf_peer_activate(freerdp_peer* client) +{ + mfPeerContext* context = (mfPeerContext*) client->context; + + rfx_context_reset(context->rfx_context); + context->activated = TRUE; + + return TRUE; +} + +void mf_peer_synchronize_event(rdpInput* input, UINT32 flags) +{ + printf("Client sent a synchronize event (flags:0x%08X)\n", flags); +} + +void mf_peer_keyboard_event(rdpInput* input, UINT16 flags, UINT16 code) +{ + printf("Client sent a keyboard event (flags:0x%04X code:0x%04X)\n", flags, code); +} + +void mf_peer_unicode_keyboard_event(rdpInput* input, UINT16 flags, UINT16 code) +{ + printf("Client sent a unicode keyboard event (flags:0x%04X code:0x%04X)\n", flags, code); +} + +void mf_peer_mouse_event(rdpInput* input, UINT16 flags, UINT16 x, UINT16 y) +{ + //printf("Client sent a mouse event (flags:0x%04X pos: %d,%d)\n", flags, x, y); +} + +void mf_peer_extended_mouse_event(rdpInput* input, UINT16 flags, UINT16 x, UINT16 y) +{ + //printf("Client sent an extended mouse event (flags:0x%04X pos: %d,%d)\n", flags, x, y); +} + +static void mf_peer_refresh_rect(rdpContext* context, BYTE count, RECTANGLE_16* areas) +{ + BYTE i; + + printf("Client requested to refresh:\n"); + + for (i = 0; i < count; i++) + { + printf(" (%d, %d) (%d, %d)\n", areas[i].left, areas[i].top, areas[i].right, areas[i].bottom); + } +} + +static void mf_peer_suppress_output(rdpContext* context, BYTE allow, RECTANGLE_16* area) +{ + if (allow > 0) + { + printf("Client restore output (%d, %d) (%d, %d).\n", area->left, area->top, area->right, area->bottom); + } + else + { + printf("Client minimized and suppress output.\n"); + } +} + +static void* mf_peer_main_loop(void* arg) +{ + int i; + int fds; + int max_fds; + int rcount; + void* rfds[32]; + fd_set rfds_set; + mfPeerContext* context; + freerdp_peer* client = (freerdp_peer*) arg; + + memset(rfds, 0, sizeof(rfds)); + + mf_peer_init(client); + + /* Initialize the real server settings here */ + client->settings->cert_file = _strdup("server.crt"); + client->settings->privatekey_file = _strdup("server.key"); + client->settings->nla_security = FALSE; + client->settings->rfx_codec = TRUE; + client->settings->suppress_output = TRUE; + client->settings->refresh_rect = TRUE; + + client->PostConnect = mf_peer_post_connect; + client->Activate = mf_peer_activate; + + client->input->SynchronizeEvent = mf_peer_synchronize_event; + client->input->KeyboardEvent = mf_peer_keyboard_event; + client->input->UnicodeKeyboardEvent = mf_peer_unicode_keyboard_event; + client->input->MouseEvent = mf_peer_mouse_event; + client->input->ExtendedMouseEvent = mf_peer_extended_mouse_event; + + client->update->RefreshRect = mf_peer_refresh_rect; + client->update->SuppressOutput = mf_peer_suppress_output; + + client->Initialize(client); + context = (mfPeerContext*) client->context; + + printf("We've got a client %s\n", client->local ? "(local)" : client->hostname); + + while (1) + { + rcount = 0; + + if (client->GetFileDescriptor(client, rfds, &rcount) != TRUE) + { + printf("Failed to get FreeRDP file descriptor\n"); + break; + } + WTSVirtualChannelManagerGetFileDescriptor(context->vcm, rfds, &rcount); + + max_fds = 0; + FD_ZERO(&rfds_set); + + for (i = 0; i < rcount; i++) + { + fds = (int)(long)(rfds[i]); + + if (fds > max_fds) + max_fds = fds; + + FD_SET(fds, &rfds_set); + } + + if (max_fds == 0) + break; + + if (select(max_fds + 1, &rfds_set, NULL, NULL, NULL) == -1) + { + /* these are not really errors */ + if (!((errno == EAGAIN) || + (errno == EWOULDBLOCK) || + (errno == EINPROGRESS) || + (errno == EINTR))) /* signal occurred */ + { + printf("select failed\n"); + break; + } + } + + if (client->CheckFileDescriptor(client) != TRUE) + break; + if (WTSVirtualChannelManagerCheckFileDescriptor(context->vcm) != TRUE) + break; + } + + printf("Client %s disconnected.\n", client->local ? "(local)" : client->hostname); + + client->Disconnect(client); + freerdp_peer_context_free(client); + freerdp_peer_free(client); + + return NULL; +} + +static void mf_peer_accepted(freerdp_listener* instance, freerdp_peer* client) +{ + pthread_t th; + + pthread_create(&th, 0, mf_peer_main_loop, client); + pthread_detach(th); +} + +static void mf_server_main_loop(freerdp_listener* instance) +{ + int i; + int fds; + int max_fds; + int rcount; + void* rfds[32]; + fd_set rfds_set; + + memset(rfds, 0, sizeof(rfds)); + + while (1) + { + rcount = 0; + + if (instance->GetFileDescriptor(instance, rfds, &rcount) != TRUE) + { + printf("Failed to get FreeRDP file descriptor\n"); + break; + } + + max_fds = 0; + FD_ZERO(&rfds_set); + + for (i = 0; i < rcount; i++) + { + fds = (int)(long)(rfds[i]); + + if (fds > max_fds) + max_fds = fds; + + FD_SET(fds, &rfds_set); + } + + if (max_fds == 0) + break; + + if (select(max_fds + 1, &rfds_set, NULL, NULL, NULL) == -1) + { + /* these are not really errors */ + if (!((errno == EAGAIN) || + (errno == EWOULDBLOCK) || + (errno == EINPROGRESS) || + (errno == EINTR))) /* signal occurred */ + { + printf("select failed\n"); + break; + } + } + + if (instance->CheckFileDescriptor(instance) != TRUE) + { + printf("Failed to check FreeRDP file descriptor\n"); + break; + } + } + + instance->Close(instance); +} + +int main(int argc, char* argv[]) +{ + freerdp_listener* instance; + + signal(SIGPIPE, SIG_IGN); + + instance = freerdp_listener_new(); + + instance->PeerAccepted = mf_peer_accepted; + + if (instance->Open(instance, NULL, 3389)) + { + mf_server_main_loop(instance); + } + + freerdp_listener_free(instance); + + return 0; +} + diff --git a/server/Mac/mfreerdp.h b/server/Mac/mfreerdp.h new file mode 100644 index 000000000..63344761e --- /dev/null +++ b/server/Mac/mfreerdp.h @@ -0,0 +1,47 @@ +/** + * FreeRDP: A Remote Desktop Protocol Implementation + * FreeRDP Mac OS X Server + * + * Copyright 2012 Marc-Andre Moreau + * + * 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. + */ + +#ifndef MFREERDP_SERVER_H +#define MFREERDP_SERVER_H + +#include +#include +#include +#include +#include +#include +#include + +struct mf_peer_context +{ + rdpContext _p; + + STREAM* s; + BOOL activated; + UINT32 frame_id; + BOOL audin_open; + RFX_CONTEXT* rfx_context; + NSC_CONTEXT* nsc_context; + WTSVirtualChannelManager* vcm; + audin_server_context* audin; + rdpsnd_server_context* rdpsnd; +}; +typedef struct mf_peer_context mfPeerContext; + +#endif /* MFREERDP_SERVER_H */ diff --git a/server/Mac/server.crt b/server/Mac/server.crt new file mode 100644 index 000000000..7ce931c26 --- /dev/null +++ b/server/Mac/server.crt @@ -0,0 +1,17 @@ +-----BEGIN CERTIFICATE----- +MIICyzCCAbOgAwIBAgIJANbqtAWwlQZuMA0GCSqGSIb3DQEBBQUAMBIxEDAOBgNV +BAMTB0ZyZWVSRFAwHhcNMDkxMDI5MDA0MTQ5WhcNMDkxMTI4MDA0MTQ5WjASMRAw +DgYDVQQDEwdGcmVlUkRQMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA +q7mxFgRbS2FYJZX7BzpNd4T/n4nEVDBY6YaObLjGpaB1TptzXTcmfDrDslTGwcEY +hTFAC4ZvY6yOURExqbph4LSgvkoa6J722RjVPfshGa4mlh2SXvTiaV26VPPxddGb +o6fbs2u029lbtBlpIVbhx5RN9vstNkll26oSZ6wfEdBNHQJLd2SU4ItWHj8zjz1f +eGxjgChHihUlwcBYKDJsKFkzHZmLrMgB37KsGlXi/WV+eEsjgvz4yP7I3TL8+GsN +MjV8fRGVEKTbKSmgunO67d5u+IaqUQb0Ad1ha1jzDQ+a6hdymrulJSIhoOVfKkwi +ptTe43FgwxVRIygJP9HjHQIDAQABoyQwIjATBgNVHSUEDDAKBggrBgEFBQcDATAL +BgNVHQ8EBAMCBDAwDQYJKoZIhvcNAQEFBQADggEBAIOdEDhOX2kbl02znltd9hCr +nV4kRPKm979RKwBNkrEuwYSlcsjAHg5MZ5itH3wFOUo2s5pjt7/vMOAg+6rOBbIa +nqr22/gKBtOmuaJLG1yjxDC2vfez7f3B26pKgxa/krM8oxiFdT9n8QbdxdkN7/D9 +3RLU/aCfgrMzXxRus7eq3kR00jnSs6ggnAfE1E9gric3vFgr1wCzdcriRXmXDfUb +hRq+4VG+ZWk16TwCofV5GVU39XWCv5HNO2swAdjkNXgI5e3tQbV3wWLZLqqYzBco +iWulAXtoCGmE81+u1Ms7hLLzpXitLZSGPu1r+sDdkKPLCmOvkAaljDQ4nBz7fIA= +-----END CERTIFICATE----- diff --git a/server/Mac/server.key b/server/Mac/server.key new file mode 100644 index 000000000..5c2f2c803 --- /dev/null +++ b/server/Mac/server.key @@ -0,0 +1,27 @@ +-----BEGIN RSA PRIVATE KEY----- +MIIEogIBAAKCAQEAq7mxFgRbS2FYJZX7BzpNd4T/n4nEVDBY6YaObLjGpaB1Tptz +XTcmf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