Date: Tue, 14 Apr 2009 14:38:33 -0700 From: Maksim Yevmenkin <maksim.yevmenkin@gmail.com> To: "Mikhail T." <mi+thun@aldan.algebra.com> Cc: "freebsd-bluetooth@freebsd.org" <freebsd-bluetooth@freebsd.org> Subject: Re: RFC: obexapp - virtual root folder for each device Message-ID: <bb4a86c70904141438y2f8742efxa9c640f21581b2ed@mail.gmail.com> In-Reply-To: <49E4EA14.80300@aldan.algebra.com> References: <bb4a86c70904131640n7cf471c0o7a56a43d722a90e1@mail.gmail.com> <49E3DB35.4030601@aldan.algebra.com> <bb4a86c70904131909k44aba88dk126d25a4f1fc3744@mail.gmail.com> <49E41DBB.5090805@aldan.algebra.com> <bb4a86c70904140934h5b967efby4e3238bd97c5ca01@mail.gmail.com> <49E4CAE1.6090506@aldan.algebra.com> <bb4a86c70904141155h205b78caq95d5f2d30a583376@mail.gmail.com> <49E4EA14.80300@aldan.algebra.com>
next in thread | previous in thread | raw e-mail | index | archive | help
--0016361e7db21a795504678aa701 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit 2009/4/14 Mikhail T. <mi+thun@aldan.algebra.com>: [...] > Slow, painful, but still progress... :-) please find attached revised patch that implements mi's (aka Mikhail) initial suggestion, i.e. use lstat(2) instead of stat(2). i've also changed it a bit to allow both cases, i.e. (1) when virtual root folder is requested and -u <user> option is set, obexapp will always run as <user>; (2) when virtual root folder is requested and _no_ -u option was specified, obexapp will run as the owner of the found virtual root folder entry (where entry is either symlink or actual subdirectory under default root folder); i've also included a patch, submitted by Ronald Klop to disable spinner in client mode for non-interactive client sessions. [...] > To summarize, you seem willing to consider the owner of the matching > entry when determining, which UID to switch to when dropping > root-privileges after chroot. The only remaining disagreement is whether > to use lstat vs. stat for the purpose. It being, literally, a > one-character change in the code, you can go ahead and begin coding the > change to match your style preferences. > > In the mean time, consider the example I just gave, showing stat being a > security hole... yes, now i get it :) sorry for being such a bonehead :) hopefully the latest patch will work for everyone. thanks, max --0016361e7db21a795504678aa701 Content-Type: text/plain; charset=US-ASCII; name="obexapp-uid4.diff.txt" Content-Disposition: attachment; filename="obexapp-uid4.diff.txt" Content-Transfer-Encoding: base64 X-Attachment-Id: f_ftj3uk8i0 SW5kZXg6IGV2ZW50LmMKPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09 PT09PT09PT09PT09PT09PT09PT09PT09PQpSQ1MgZmlsZTogL3Vzci9sb2NhbC9jdnMvcG9ydHMv b2JleGFwcC9ldmVudC5jLHYKcmV0cmlldmluZyByZXZpc2lvbiAxLjYKZGlmZiAtdSAtcjEuNiBl dmVudC5jCi0tLSBldmVudC5jCTUgSmFuIDIwMDkgMTY6Mzc6MjUgLTAwMDAJMS42CisrKyBldmVu dC5jCTE0IEFwciAyMDA5IDIxOjIzOjE2IC0wMDAwCkBAIC0xLDcgKzEsNyBAQAogLyoKICAqIGV2 ZW50LmMKICAqCi0gKiBDb3B5cmlnaHQgKGMpIDIwMDIgTWFrc2ltIFlldm1lbmtpbiA8bV9ldm1l bmtpbkB5YWhvby5jb20+CisgKiBDb3B5cmlnaHQgKGMpIDIwMDItMjAwOSBNYWtzaW0gWWV2bWVu a2luIDxtX2V2bWVua2luQHlhaG9vLmNvbT4KICAqIEFsbCByaWdodHMgcmVzZXJ2ZWQuCiAgKgog ICogUmVkaXN0cmlidXRpb24gYW5kIHVzZSBpbiBzb3VyY2UgYW5kIGJpbmFyeSBmb3Jtcywgd2l0 aCBvciB3aXRob3V0CkBAIC0zMiw2ICszMiw3IEBACiAjaW5jbHVkZSA8Ymx1ZXRvb3RoLmg+CiAj aW5jbHVkZSA8b2JleC5oPgogI2luY2x1ZGUgPHN0ZGlvLmg+CisjaW5jbHVkZSA8dW5pc3RkLmg+ CiAKICNpbmNsdWRlICJjb21wYXQuaCIKICNpbmNsdWRlICJvYmV4YXBwLmgiCkBAIC0xMzEsNyAr MTMyLDcgQEAKIAogCWxvZ19kZWJ1ZygiJXMoKTogTWFkZSBzb21lIHByb2dyZX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tPnVzZXIpOworCQkJcmV0dXJuICgtMSk7CisJCX0KKworCQls b2dfZGVidWcoIiVzKCk6IFJlcXVlc3RlZCB0byBydW4gYXMgJyVzJywgdWlkPSVkLCBnaWQ9JWQi LAorCQkJX19mdW5jX18sIGNvbnRleHQtPnVzZXIsIHB3LT5wd191aWQsIHB3LT5wd19naWQpOwor CisJCWNvbnRleHQtPnVpZCA9IHB3LT5wd191aWQ7CisJCWNvbnRleHQtPmdpZCA9IHB3LT5wd19n aWQ7CisJfSBlbHNlIHsKKwkJY29udGV4dC0+dWlkID0gZ2V0dWlkKCk7CisJCWNvbnRleHQtPmdp ZCA9IGdldGdpZCgpOworCX0KKworCS8qIFNldCBkZWZhdWx0IHJvb3QgKi8KKwlpZiAoY29udGV4 dC0+cm9vdFswXSA9PSAnXDAnKSB7CisJCWlmIChwdyA9PSBOVUxMKQorCQkJc3RybGNweShjb250 ZXh0LT5yb290LCBPQkVYQVBQX1JPT1RfRElSLCBQQVRIX01BWCk7CisJCWVsc2UKKwkJCXN0cmxj cHkoY29udGV4dC0+cm9vdCwgcHctPnB3X2RpciwgUEFUSF9NQVgpOworCX0KKworCWlmIChjaGRp cihjb250ZXh0LT5yb290KSA8IDApIHsKKwkJbG9nX2VycigiJXMoKTogQ291bGQgbm90IGNoZGly KCVzKS4gJXMgKCVkKSIsCisJCQlfX2Z1bmNfXywgY29udGV4dC0+cm9vdCwgc3RyZXJyb3IoZXJy bm8pLCBlcnJubyk7CisJCXJldHVybiAoLTEpOworCX0KKworCWxvZ19kZWJ1ZygiJXMoKTogVXNp bmcgaW5pdGlhbCByb290ICVzIiwgX19mdW5jX18sIGNvbnRleHQtPnJvb3QpOworCisJcmV0dXJu ICgwKTsKK30gLyogb2JleGFwcF9zZXJ2ZXJfc2V0X2luaXRpYWxfcm9vdCAqLworCisvKgorICog U2V0IGRldmljZSBzcGVjaWZpYyBzZXJ2ZXIgcm9vdAorICovCisKK3N0YXRpYyBpbnQKK29iZXhh cHBfc2VydmVyX3NldF9kZXZpY2Vfcm9vdChjb250ZXh0X3AgY29udGV4dCkKK3sKKwljaGFyIGNv bnN0CSpyb290W10gPSB7IE5VTEwsIE5VTEwsIE5VTEwgfTsKKwlzdHJ1Y3QgaG9zdGVudAkqaGU7 CisJc3RydWN0IHN0YXQJc2I7CisJaW50CQluOworCisJbiA9IDA7CisKKwloZSA9IGJ0X2dldGhv c3RieWFkZHIoKGNoYXIgY29uc3QgKikgJmNvbnRleHQtPnJhZGRyLAorCQkJc2l6ZW9mKGJkYWRk cl90KSwgQUZfQkxVRVRPT1RIKTsKKwlpZiAoaGUgIT0gTlVMTCkKKwkJcm9vdFtuICsrXSA9IChj aGFyIGNvbnN0ICopIGhlLT5oX25hbWU7CisKKwlyb290W24gKytdID0gYnRfbnRvYSgmY29udGV4 dC0+cmFkZHIsIE5VTEwpOworCisJcm9vdFtuICsrXSA9ICJkZWZhdWx0IjsKKworCWZvciAobiA9 IDA7IG4gPCAzOyBuICsrKSB7CisJCWlmIChyb290W25dID09IE5VTEwpCisJCQlicmVhazsKKwor CQlsb2dfZGVidWcoIiVzKCk6IENoZWNraW5nIGZvciAlcy8lcyBzdWJkaXJlY3RvcnkiLAorCQkJ X19mdW5jX18sIGNvbnRleHQtPnJvb3QsIHJvb3Rbbl0pOworCisJCWlmIChsc3RhdChyb290W25d LCAmc2IpIDwgMCkgeworCQkJaWYgKGVycm5vID09IEVOT0VOVCkKKwkJCQljb250aW51ZTsKKwor CQkJbG9nX2VycigiJXMoKTogQ291bGQgbm90IGxzdGF0KCVzLyVzKS4gJXMgKCVkKSIsCisJCQkJ X19mdW5jX18sIGNvbnRleHQtPnJvb3QsIHJvb3Rbbl0sCisJCQkJc3RyZXJyb3IoZXJybm8pLCBl cnJubyk7CisKKwkJCXJldHVybiAoLTEpOworCQl9CisKKwkJc3RybGNhdChjb250ZXh0LT5yb290 LCAiLyIsIFBBVEhfTUFYKTsKKwkJc3RybGNhdChjb250ZXh0LT5yb290LCByb290W25dLCBQQVR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GJp bmFyeSBmb3Jtcywgd2l0aCBvciB3aXRob3V0CkBAIC00MjUsOSArNDI1LDcgQEAKIAkgKiBzdHJp bmcsIHNvIGFsd2F5cyBwYXNzIGEgY29weS4KIAkgKi8KIAotCXN0cm5jcHkobiwgbmFtZSwgc2l6 ZW9mKG4pKTsKLQluW3NpemVvZihuKSAtIDFdID0gJ1wwJzsKLQorCXN0cmxjcHkobiwgbmFtZSwg c2l6ZW9mKG4pKTsKIAlzbnByaW50Zih0ZW1wLCB0ZW1wX3NpemUsICIlcy9YWFhYWFhYWCIsIGRp cm5hbWUobikpOwogCiAJcmV0dXJuIChta3N0ZW1wKHRlbXApKTsK --0016361e7db21a795504678aa701--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bb4a86c70904141438y2f8742efxa9c640f21581b2ed>