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

Stop property page & display Icon during silent install

Post Reply
docfxit
20
20
Posts: 57
Joined: 2005-05-10 18:48

Stop property page & display Icon during silent install

Post by docfxit »

I am trying to create a silent install.
After the install the properties page comes up. I'd like to know how to configure the install so the properties page doesn't come up.
I would also like to know how to make the icon in the tools bar to show.
Running win7

VNC UltraVNC_1_2_17_X86_Setup.exe /VERYSILENT /loadinf=UltraVNC.inf, C:\Users\Gary\AppData\Local\Temp\UltraVNC open

ultravnc.inf

Code: Select all

[Setup]
Lang=en
Dir=C:\Programs\UltraVNC
Group=UltraVNC
NoIcons=0
SetupType=full
Components=ultravnc_server,ultravnc_viewer
Tasks=installservice,startservice
ultravnc.ini

Code: Select all

[admin]
UseRegistry=0
MSLogonRequired=0
NewMSLogon=0
DebugMode=2
Avilog=0
path=C:\Programs\ultravnc
kickrdp=0
service_commandline=
DebugLevel=10
DisableTrayIcon=0
LoopbackOnly=0
UseDSMPlugin=1
AllowLoopback=1
AuthRequired=1
ConnectPriority=1
DSMPlugin=SecureVNCPlugin.dsm
AuthHosts=
AllowShutdown=1
AllowProperties=1
AllowEditClients=1
FileTransferEnabled=1
FTUserImpersonation=1
BlankMonitorEnabled=1
BlankInputsOnly=0
DefaultScale=1
CaptureAlphaBlending=0
BlackAlphaBlending=1
SocketConnect=1
HTTPConnect=1
XDMCPConnect=0
AutoPortSelect=0
PortNumber=5909
HTTPPortNumber=5800
IdleTimeout=0
RemoveWallpaper=1
RemoveAero=1
QuerySetting=2
QueryTimeout=10
QueryAccept=1
QueryIfNoLogon=0
primary=1
secondary=1
InputsEnabled=1
LockSetting=0
LocalInputsDisabled=0
EnableJapInput=0
FileTransferTimeout=1
clearconsole=0
KeepAliveInterval=5
accept_reject_mesg=
rdpmode=0
DSMPluginConfig=
IdleInputTimeout=0
[ultravnc]
passwd=9999
passwd2=somepassword
[poll]
TurboMode=1
PollUnderCursor=1
PollForeground=1
PollFullScreen=1
OnlyPollConsole=0
OnlyPollOnEvent=0
EnableDriver=1
EnableHook=1
EnableVirtual=0
SingleWindow=0
SingleWindowName=
MaxCpu=40
[Permissions]
[admin_auth]
group1=
group2=
group3=
locdom1=0
locdom2=0
locdom3=0
Thanks,

Docfxit
Last edited by docfxit on 2018-04-15 23:25, edited 1 time in total.
User avatar
Rudi De Vos
Admin & Developer
Admin & Developer
Posts: 6831
Joined: 2004-04-23 10:21
Contact:

Re: Stop property page & display Icon during silent install

Post by Rudi De Vos »

Property page popup if no password has been set.
mhertz
20
20
Posts: 39
Joined: 2018-02-27 20:19

Re: Stop property page & display Icon during silent install

Post by mhertz »

What i'd do, is run the installer with "/VERYSILENT /loadinf=UltraVNC.inf" and then copy over your ultravnc.ini to the installed folder and restart the service. You can automate it fully from a batchfile, if you cannot do it yourself, I can whip one up for you. Btw, I tested the above command with the 64bit EXE installer(not MSI) and no properties popup came up afterwards and the "default" passwords where set(random chars I believe). About icons, you have disabled icons in your inf. If your're referring to the system-tray icon, it wasen't disabled in my test. If it's about the windows hidden unused icons, then there's a reg-tweak to disable it I can post if needed(or can be done manually, very easy).
User avatar
Rudi De Vos
Admin & Developer
Admin & Developer
Posts: 6831
Joined: 2004-04-23 10:21
Contact:

Re: Stop property page & display Icon during silent install

Post by Rudi De Vos »

The inno setup installer (exe)
set a random password when no password exist in ultravnc.ini
Internal is use a uvnc setpasswd.exe ( should be in the install folder)

setpasswd.exe set a random or given password
setpasswd.exe [full passwd] [readonly passwd]
mhertz
20
20
Posts: 39
Joined: 2018-02-27 20:19

Re: Stop property page & display Icon during silent install

Post by mhertz »

Thanks Rudi for clarification - I did before making my reply-post to the OP, test making an empty folder with the OP's ultravnc.ini which had a password set already + other settings, and then install silent the IS installer with the OP's INF, I just changed the path to the english "standard" one, instead of the OP's localized path and I expected it to keep password, but it wiped the ultravnc.ini and made the two lines with random passwords. Since you wrote this now, then I wen't back to my win10 testing VM and tested it again, and you're of course correct as it worked perfectly - i'm guessing the reason it didn't work in my first test, was because I remember I had named the ultravnc.ini file as UltraVNC.ini, as that was what the OP had it named as, and i'm thinking this messed it up, but of course I should have named it correctly, but didn't remember the correct name(as in correct case used) at the time.

The setpasswd.exe command-line tool for setting password from batch-file is brilliant, as that's the only thing I change usually after an install - thank you!
docfxit
20
20
Posts: 57
Joined: 2005-05-10 18:48

Re: Stop property page & display Icon during silent install

Post by docfxit »

mhertz wrote:Thanks Rudi for clarification - I did before making my reply-post to the OP, test making an empty folder with the OP's ultravnc.ini which had a password set already + other settings, and then install silent the IS installer with the OP's INF, I just changed the path to the english "standard" one, instead of the OP's localized path and I expected it to keep password, but it wiped the ultravnc.ini and made the two lines with random passwords. Since you wrote this now, then I wen't back to my win10 testing VM and tested it again, and you're of course correct as it worked perfectly - i'm guessing the reason it didn't work in my first test, was because I remember I had named the ultravnc.ini file as UltraVNC.ini, as that was what the OP had it named as, and i'm thinking this messed it up, but of course I should have named it correctly, but didn't remember the correct name(as in correct case used) at the time.
Thank you both for looking at this.
Thank you mhertz for taking the time to run my files.

I have changed ultravnc.ini to lower case when I write the file before the install. I have added a few lines to the .ini file that was missing in the file I write. All the lines that are written when the ultravnc.ini was replaced by the installer are now in the .ini file I write out before the install.
After the install the ultravnc.ini shows a random password instead of the password I provide in the ultravnc.ini file. The icon in the system tray is now showing correctly.
The Property Page is not coming up any more.
Am I not supposed to run the install with these parameters?
VNC UltraVNC_1_2_17_X86_Setup.exe /VERYSILENT /loadinf=ultravnc.inf, C:\Users\Gary\AppData\Local\Temp\UltraVNC, open
in the post from Mhertz he shows running it with "/VERYSILENT /loadinf=ultravnc.inf" only
The only other difference I can think of is your testing was with the 64bit version and my testing is with the 32bit version.
When I provide the password, I don't understand why it would create a random password.

Thanks,
Docfxit
mhertz
20
20
Posts: 39
Joined: 2018-02-27 20:19

Re: Stop property page & display Icon during silent install

Post by mhertz »

You're very welcome! :)

I tested it again with the 32 bit EXE installer(very first in the download list), though I used my own INF this time(generated with a run first with /saveinf=uvnc.inf) and i'm testing in a win10 VM, so not win7 like you, but shouldn't matter I think.

Yes, the command to run is: "UltraVNC_1_2_17_X86_Setup.exe /verysilent /loadinf=uvnc.inf", You can add "/norestart" too, but rarely needed(only once the installer wanted to reboot, though I can't remember if it was at uninstall or install, but normally it's never needed, neither with in or uninstall). The other commands I don't know where you got from, but doesn't seem standard as far as I know. /verysilent and /loadinf are standard silent commands often for inno setup installers I believe.

Anyway, this will make an install with a new random generated password, because there isn't any already. The command/INF you run to install only sets a few parameters, but not things like passwords, and the ultravnc.ini isn't automatically copied over, or used, you have to do it yourself. So you have two choices: Either do what I just did in my testing; create the dir which you listed as install dir in the INF, and add the ultravnc.ini into that dir, nothing else, and then run the installer with the silent commands listed previously. This works and retains your password and shows the icon in systray(unless you've disabled it in your old ultravnc.ini of course). Are you sure it's not just hidden behind that little white "arrow" next to the other icons there? The other option is to create the dir first, and then just run the installer with the silent commands/INF and then afterwards replace the ultravnc.ini in the install-dir with your old one and restart the service(net stop uvnc_service; net start uvnc_service).

Actually, there's two more choices, a third option, as per Rudi's post, if only needing password changed - after the silent install you run from an admin cmd/batchfile: "%programfiles%\uvnc bvba\UltraVNC\setpasswd.exe" PASSWORD. Change dir to your installed folder, and add possible another viewonly password if wanted, after the first password. The fourth option, preferably from a batchfile, is to just make the dir, copy all the needed files over, and install winvnc as service etc, but no reason imho to go that route.

Good luck! :)
docfxit
20
20
Posts: 57
Joined: 2005-05-10 18:48

Re: Stop property page & display Icon during silent install

Post by docfxit »

Thank you very much for all the insight. And for the all the work arounds.

Do you have any idea why the simple approach isn't working?
I created the folder ultravnc, put ultravnc.ini in the folder. Included the password in the ultravnc.ini file. Then installed ultravnc in the folder.
Why would the install generate a random password when I included the password?

Thanks,

Docfxit
mhertz
20
20
Posts: 39
Joined: 2018-02-27 20:19

Re: Stop property page & display Icon during silent install

Post by mhertz »

It works for me in my tests, also with x86 installer. Before I go test again with your files on the x86 installer, then am I understanding you correct in that you've made the empty folder "C:\Programs\UltraVNC" and copied over your ultravnc.ini to this folder, which includes a password, and then from another folder you ran the installer with "/verysilent /loadinf=ultravnc.inf". This should work, hence my question :)
docfxit
20
20
Posts: 57
Joined: 2005-05-10 18:48

Re: Stop property page & display Icon during silent install

Post by docfxit »

That is exactly correct. I wonder what I am doing different than you? I am running the install with and account that has administrator privileges and I am running it as administrator.

Thanks,
Docfxit
mhertz
20
20
Posts: 39
Joined: 2018-02-27 20:19

Re: Stop property page & display Icon during silent install

Post by mhertz »

You're right, it did this for me too, sorry. Give me alittle time to investigate this after I have eaten, and i'll post you which of the things that differ between us which is the culprit through some elimination-testings. It's either not a valid password, or because of the changed folder-name or because of placement of password lines in the ini. I always set the password from the GUI and then backup the ini for reinstalls, and don't change it directly because it's hashed/encrypted I believe, so probably in there lies the problem. Later :)

Edit: Ohh, you just obfuscated the password of course, sorry...

Edit2: You did set the password from GUI right and just obfuscated the password for the post here correct?
mhertz
20
20
Posts: 39
Joined: 2018-02-27 20:19

Re: Stop property page & display Icon during silent install

Post by mhertz »

You don't have to answer the previous questions. The answer to your question is that if using a valid password generated by ultravnc(either direct or through setpaswd.exe), so 18 chars long, then the password will be retained, if found in the INI, during install. Hope this helps, and sorry if I wasn't properly clear about that previously :)
docfxit
20
20
Posts: 57
Joined: 2005-05-10 18:48

Re: Stop property page & display Icon during silent install

Post by docfxit »

mhertz wrote:You don't have to answer the previous questions. The answer to your question is that if using a valid password generated by ultravnc(either direct or through setpaswd.exe), so 18 chars long, then the password will be retained, if found in the INI, during install. Hope this helps, and sorry if I wasn't properly clear about that previously :)
I think the key to what you just said was "a valid password generated by ultravnc".
I believe you have been using an ultravnc.ini file that had been created by UltraVNC.
I have created and written the ultravnc.ini file from scratch. So the password showing above is the exact password I would like it to be. During the install instead of UltraVNC taking my password and hash/encrypting it, The install created a random password. The install program obviously recognizes it's not a hash/encrypted password. It would be nice if the install program would hash/encrypt the password it finds in the file instead of creating a random password.

Thanks,
Docfxit
mhertz
20
20
Posts: 39
Joined: 2018-02-27 20:19

Re: Stop property page & display Icon during silent install

Post by mhertz »

Yes, sorry I see I wasn't clear about this previously! If not wanting to use the ultravnc GUI to change passwords, then you can also copy setpasswd.exe in addition to the ultravnc.ini into the folder to have ultravnc be installed into, and then before install run "setpasswd.exe PASSWORD", or just run setpasswd.exe after the install as it already is in place. Last workaround is to use http://www.sysworksoft.net/products/vncpwd.html and run "vncpwd.exe /e:PASSWORD" which will print out the encrypted password on the screen and you can copy/paste it into the ultravnc.ini's password field value.

I know you prefer the installer to be "smarter", but just some few tips regardless :)

Edit: Official vncpwd download link down, so found alternative link for latest version: http://www.netware-server.de/download/t ... pwd112.exe

Edit2: Rudi, for me then setpasswd.exe doesn't work on win10-1709-home - it fails with a windows dialog about the program encountered an error and failed to run. I ran it through elevated cmd-prompt, both using full path and also next trying first cd'ing to install dir and then running it, with same result? I don't get it, as it obviously works since I believe I read the installer calls it during install.

Edit3: Rudi, running setpasswd.exe works for me without parameters, but fails with above mentioned error whenever trying a parameter(password). I did "net stop uvnc_service" before running it, and also with uvnc_service started as a test, with same result. Sorry in advance if it's me that's doing something wrong :)

Edit4: Yep, sure thing it was my own stupidity, sorry :) I found out my issue, in that viewonly password where mandatory whereas I thought it was optional, and also tried adding "" after the main password, but now I see that adding two parameters(i.e. passwords) works as expected. I never myself define a viewonly password from the GUI, so didn't thought I needed it either with setpasswd.exe. Sorry again for the noise! :)

Edit5: Doh, sorry again! Figures that the time I tested it in previous edit, my tested passwords where of precisely 8 chars that time(test1234 - test9876) - this later(just now), got me thinking if that wasen't the sole reason for it working, and sure enough, now testing works fine also with only a main password without a viewonly. I knew there where only supported 8 chars in the RFB protocol, but in the GUI I always entered more than 8 and then it just cut the remaining off I'd guess when writing it into the ini encrypted, but with setpasswd.exe you need to use max 8 chars or else the error reported previously. Sorry again for the noise!
Post Reply