Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

installer fails without admin permissions #783

Closed
donovaly opened this issue Feb 9, 2016 · 15 comments
Closed

installer fails without admin permissions #783

donovaly opened this issue Feb 9, 2016 · 15 comments

Comments

@donovaly
Copy link

donovaly commented Feb 9, 2016

The new Win installer of JabRef 3.x does not check if the user that executes the installer has admin privileges or not.

It should be:

  • if the user has admin permissions, the installer should propose to install for all users of the PC (with an option to install only for the current user)
  • if the user has no admin permissions, the installer must install only for the current user

Currently the installer tries to install for all users, also if the user doesn't have admin permissions - which will of course fail. (As an expert one can already change the install path but the vast majority does not know the correct install location for a non-admin user.)

@matthiasgeiger
Copy link
Member

Which Windows Version are you using?

At least for my Win10 System the 64bit installer asks for Admin rights using the usual UAC dialog.

@donovaly
Copy link
Author

donovaly commented Feb 9, 2016

Which Windows Version are you using?

Win 7 64bit

At least for my Win10 System the 64bit installer asks for Admin rights using the usual UAC dialog.

Here not.
However, there is no reason to force Admin permissions if the user don't have them. It was possible to install JabRef 2.x as a non-admin user without problems. I bundle JabRef with the win installer of LyX (and once wrote the JabRef 2.x installer). If JabRef disallows to install as normal user, I can no longer bundle because installing as non-admin is a very often requested feature that the LyX installer provides. (especially in companies and universities one doesn't have admin permissions it should be possible to use LyX and JabRef there too)
From the technical position forcing admin permissions is only necessary to install a program for all users of a PC and/or if one needs to install Windows services or drivers. And JabRef doesn't install services nor drivers.

@donovaly
Copy link
Author

donovaly commented Feb 9, 2016

At least for my Win10 System the 64bit installer asks for Admin rights using the usual UAC dialog.

Here not.

This is also true for Win 10. Just run the JabRef installer as non-admin user and you will see this.

@matthiasgeiger
Copy link
Member

Okay - thanks for the clarification. I can see your point now.
Using the install4j installer it is generally possible to install JabRef 3.X - but the default install directory is "wrong" as it points to the "Program Files" dir - where a normal user has no write priviledges.

So we should configure the new installer, that it is able to detect whether a user has admin rights - or not - and set the default install directory accordingly.

@koppor Can you do this?

@koppor
Copy link
Member

koppor commented Feb 11, 2016

Maybe we need the admin rights to create file associations. I am unsure about that.

Otherwise, we could simply create a launcher, would that help?

@stefan-kolb stefan-kolb added this to the v3.3 milestone Feb 11, 2016
@donovaly
Copy link
Author

Maybe we need the admin rights to create file associations.

This is not necessary. if the user doesn't have admin permissions you can set the file associations via the HKCU registry tree only for the current user. See the installer of JabRef 2.x as reference how and that this works.

@koppor koppor self-assigned this Mar 8, 2016
@stefan-kolb
Copy link
Member

There are two options:

  • We can choose the directory automatically whether there are privileges
  • We can show a form where the user chooses if he wants to install for all users or not

@stefan-kolb
Copy link
Member

Ok, I got a version running that lets you select the installation scope. You can test it here. Please confirm if this does solve your problems.

http://builds.jabref.org/install-privileges/

@stefan-kolb
Copy link
Member

Ok, this is implemented know. The installer automatically decides whether the user has to install in home directory or not.

@donovaly Please check at http://builds.jabref.org/install-privileges/

@koppor
Copy link
Member

koppor commented Apr 11, 2016

It works here. When the same user can acquire admin rights, it asks for admin rights. If the user cannot acquire admin rights, the setup does not popup asking for other user credentials. When using other applications, these also ask for other credentials.

Is it possible that the installer asks for admin credentials when the current user is not an admin?

@koppor
Copy link
Member

koppor commented Apr 11, 2016

For reference: The PR is #1125.

@donovaly
Copy link
Author

donovaly commented May 7, 2016

@donovaly Please check at http://builds.jabref.org/install-privileges/

This link is dead.

@stefan-kolb
Copy link
Member

@donovaly This has been merged already. You can try out the new final version 3.3.

@donovaly
Copy link
Author

donovaly commented May 7, 2016

I tested now the installer of JabRef 3.3. I requested:

"- if the user has admin permissions, the installer should propose to install for all users of the PC (with an option to install only for the current user)

  • if the user has no admin permissions, the installer must install only for the current user"

We now have
"- if the user has admin permissions, the installer should propose to install for all users of the PC

  • if the user has no admin permissions, the installer must install only for the current user"

So it is much better than before and I am now able to bundle JabRef again with the installer of the program LyX. It would nevertheless be helpful if there is the requested option to install only for the current user although the current user as admin.

@stefan-kolb
Copy link
Member

I had this inplemented in a previous commit, but we decided to keep it simple for now. Dunno what the others think @simonharrer

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants