Update: UltraVNC 1.4.3.6 and UltraVNC SC 1.4.3.6: viewtopic.php?t=37885
Important: Please update to latest version before to create a reply, a topic or an issue: viewtopic.php?t=37864

Join us on social networks and share our announcements:
- Website: https://uvnc.com/
- GitHub: https://github.com/ultravnc
- Mastodon: https://mastodon.social/@ultravnc
- Facebook: https://www.facebook.com/ultravnc1
- X/Twitter: https://twitter.com/ultravnc1
- Reddit community: https://www.reddit.com/r/ultravnc
- OpenHub: https://openhub.net/p/ultravnc

change password from command line?

Post Reply
jooray
Posts: 1
Joined: 2006-10-21 14:02

change password from command line?

Post by jooray »

Hello,


I'm stuck with my machine few hundred kilometers away. I seem to no longer be able to log in (it could be, that I mistyped password when I was changing it last week).

I can however SSH to the machine with no problems. I tried importing registry keys I created on local machine with different password and then doing

sc stop winvnc
sc query winvnc
(it was stopped)
and then

sc start winvnc

But the password seems to always be incorrect. I don't know which key to create/update or where could a problem be. Is there some kind of howto about changing UltraVNC Password from command line (or switching to MS authentication? I know Administrator password of that machine). I also tried WinVNC single click client, it seems to connect to my machine, but no screen appears (but as I'm executing it from SSH command line, this could be because that session has no screen attached).

WinVNC -connect hostname::5500 does not seem to connect back to my vncviewer in listen mode. I disabled firewall using

netsh firewall set opmode=disable

And I can confirm it's disabled (a port that was denied in windows firewall is now accessible). Any hints would be appreciated.


Thanks,

J.
redge
1000
1000
Posts: 6797
Joined: 2004-07-03 17:05
Location: Switzerland - Geneva

Re: change password from command line?

Post by redge »

vncpwd
[topic=6668][/topic]
UltraVNC 1.0.9.6.1 (built 20110518)
OS Win: xp home + vista business + 7 home
only experienced user, not developer
edisongotan
Posts: 1
Joined: 2011-07-20 20:41

Re: change password from command line?

Post by edisongotan »

Is there a new way for the new UltraVNC? Just need to change the password in the ultravnc.ini file using command line.
YY
200
200
Posts: 996
Joined: 2006-11-13 15:11

Re: change password from command line?

Post by YY »

You may do this with some third party tools, like Inifile

e.g.

Code: Select all

INIFILE.exe ultravnc.ini [ultravnc] passwd=xxxxxxxxxxxxxxx

INIFILE.exe ultravnc.ini [ultravnc] passwd2=yyyyyyyyyyyyyyy
mtrento
Posts: 1
Joined: 2015-10-22 09:05

Re: change password from command line?

Post by mtrento »

Hello
i'm using version 1.0.9.6.2 and replacing password in ultravnc.in with either inifile.exe or manualy gives the following error after service restart :
"this server does have a valid password"
looks like ultravnc is using somewhere a checksum to avoid this.
i have found a workaround by switching to registry configuration instead of ultravnc.ini

here is a piece of code to change password and switch to registry .

Code: Select all

set INIFILE=\\domain.local\netlogon\script\vnc\inifile.exe
sc stop uvnc_service

rem wait 10sec
ping 127.0.0.1 -n 10 -w 1000 >nul

rem even when service is stopped , the process remains in memory
taskkill /F  /FI "IMAGENAME eq winvnc.exe"
ping 127.0.0.1 -n 3 -w 1000 >nul

REG ADD HKLM\SOFTWARE\ORL\WinVNC3 /v MSLogonRequired /t REG_DWORD /d 0 /f
REG ADD HKLM\SOFTWARE\ORL\WinVNC3 /v NewMSLogon /t REG_DWORD /d 0 /f
REG ADD HKLM\SOFTWARE\ORL\WinVNC3 /v Password /t REG_BINARY /d XXXXXXXXXXXX /f

%INIFILE% "C:\Program Files\UltraVNC\ultravnc.ini" [ultravnc] passwd=XXXXXXXXXXXX
%INIFILE% "C:\Program Files\UltraVNC\ultravnc.ini" [admin] UseRegistry=1

sc start uvnc_service
User avatar
Rudi De Vos
Admin & Developer
Admin & Developer
Posts: 6832
Joined: 2004-04-23 10:21
Contact:

Re: change password from command line?

Post by Rudi De Vos »

You can also use the set password utulity

setpasswd.exe full_passwd viewonly_passwd

( setpasswd is in the same folder as winvnc.exe)
Post Reply