Date: Wed, 24 Aug 2016 14:53:46 +0200 From: Gert Doering Message-ID: <20160824125346.GK78279@...1296...> References: <57A3C76A.1020809@...277...> <76eb908d-b7b3-7425-5340-e4cd5726fbd1@...2080...> <3642cff2-6233-0a28-2a39-36513f008ab4@...277...> <20160823123439.GA78279@...1296...> <57BD5780.2030204@...1147...> <57BD64D9.8010607@...1147...> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="zJNEIfy6us2B785O" Content-Disposition: inline In-Reply-To: <57BD64D9.8010607@...1147...> Subject: Re: [Openvpn-devel] Win10 Tun Server +Standard W10 User +OVPN Interactive Service +OVPN GUI List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Jan Just Keijser Cc: openvpn-devel@lists.sourceforge.net --zJNEIfy6us2B785O Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Hi, On Wed, Aug 24, 2016 at 11:11:53AM +0200, Jan Just Keijser wrote: > >> just for my understanding: how would a user run an up/down script with > >> *USER* credentials (necessary to map a share or printer, for example) = in > >> this scenario? [..] > Actually, how would a (clueless) user do this at all, using the=20 > interactive service? which part should be run with admin privs, which=20 > part shouldn't ? which credentials are available to the interactive=20 > service (and any up/down scripts it may run) ? should a user use a GUI= =20 > up/down script (I know the old GUI supported this) instead? If the iservice is around, it's all totally straightforward :-) - you run your --up script from the config.ovpn and it is run with your user credentials. Iservice works like this (we have a documentation page coming, but that's not there yet) - the GUI runs as "me" (gert) - the iservice runs as "local service", maximum privileges - the GUI connects to the iservice, and asks it "run openvpn.exe with the following arguments, using the credentials of the user the GUI runs with" (windows can do this - pass credentials across a pipe, which you can't fake) - the iservice forks openvpn.exe, and runs this as user (gert), and keeps a "service pipe" between iservice and openvpn.exe - if openvpn.exe wants to do ifconfig/route/dns stuff, it sends these as requests over the service pipe to the iservice, who will then execute them (and clean up should openvpn crash) - --up scripts are run by openvpn.exe itself, which is already running as "gert", so, all privileges are nicely in place so this cannot be used anymore for privilege escalation to admin (by running an --up script from openvpn which is run-as-admin). gert --=20 USENET is *not* the non-clickable part of WWW! //www.muc.de/~ge= rt/ Gert Doering - Munich, Germany gert@...1296... fax: +49-89-35655025 gert@...1297... --zJNEIfy6us2B785O Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQCVAwUBV72Y2qkuBuNlUUl1AQKR7AQAgyGv7JQgQYyvuF2oc+RLfaJk7GOVNs1y VX2/lFmFWe3P2c15RCO8pCbBF4Q/Qa/thu6Cgdpb6MEkT2RYbRJdWBHwM2c4DXTk Kx6WsNX3VynBgZwqwMOK+T0wmRt6CpvveFvI74V6mShhzIgaTxxs6bGT0KPfG2J8 2nVFurIN6SU= =F7hi -----END PGP SIGNATURE----- --zJNEIfy6us2B785O--