How to disable "do not allow drive redirection" local policy not using GUI?

I need to do it preferably using powershell/batch but after searching there is only some instructions for creatig adm/admx files. Is there an easier way to do this?

I've also found a registry key with the setting HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services!fDisableCdm

But it looks like it reflects only changes in GUI. Manual changes in registry doesn't work which makes sense from security point of view.

Thanks


You need to run gpupdate /force after these registry keys manipulation, and to relogin to the server