[FreeNX-kNX] .nx and .ssh in Windows profile not deletable

Rupert Kolb rupert.kolb at med.uni-tuebingen.de
Fri Mar 7 08:32:51 UTC 2008


Holger Krull schrieb:
> Rupert Kolb schrieb:
>   
>> Holger Krull schrieb:
>>     
>>> Rupert Kolb schrieb:
>>>       
>>>>>> connecting from windows clients with a (recent) nomachine client to an 
>>>>>> openSUSE FreeNX 0.7.1 we get .nx and .ssh directories in the local 
>>>>>> (temporary) profiles of the windows users.
>>>>>>
>>>>>> They are not deletable.
>>>>>>         
>>>>>>             
>>>>> They are, if you add access rights for the group administrators.
>>>>> The nomachine client creates these files with full controll access for the owner only. Windows default is full controll for the windows user, system and the group administrator. If you want them to get automatically deleted you will need to change the acls first.
>>>>>       
>>>>>           
>>>> How can I do that? It seems that the nomachine client does ignore any 
>>>> access control settings in "documents and settings", which other 
>>>> newly-created files and folders inherit usually.
>>>>     
>>>>         
>>> Yes, inheritance is disabled.
>>> You need to start the nx client in a cmd file that sets the acls with cacls.exe
>>>   
>>>       
>> ... more questions...  Do you have an example script?
>>     
>
> Not yet. Put the following in test.cmd 
>
> "%ProgramFiles%\NX Client for Windows\nxclient.exe"
> cacls "%USERPROFILE%\.nx" /T /G SYSTEM:F 
> cacls "%USERPROFILE%\.ssh" /T /G SYSTEM:F
>
> I didn't test this.
> If you want to allow the Administrator to delete this, you will need an additional /G Administrator:F
>
> Unfortunately the name Administrator changes with the language of Windows.
>   
One more flag is necessary for the cacls: "/E", otherwise the control 
settings will be replaced!

It works!
This is the script "MyApplication.cmd":

"%ProgramFiles%\NX Client for Windows\nxclient.exe" --session "\path_to_nx_sessions\MyApplication.nxs"
cacls "%USERPROFILE%\.nx" /T /E /G SYSTEM:F 
cacls "%USERPROFILE%\.ssh" /T /E /G SYSTEM:F


With starting the shell minimized and putting a nice icon to the script, 
the users take them for a local program.

Somewhat critical is the period between the start of the script and the 
start of the application, which the nx client starts:
The access control settings are not set properly yet. If something 
crashes there, one have to fix the .nx and .ssh files manually.

I would prefer, that nomachine would change the default settings.

Thank you for the help.

Rupert



More information about the FreeNX-kNX mailing list