Re: קוד פתוח אלק
Amos Shapira wrote: Who's the power behind linux.org.il right now? Me. Always been me. (Well, ever since Linux.org.il stopped pointing to IGLU's site.) = To unsubscribe, send mail to [EMAIL PROTECTED] with the word unsubscribe in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: קוד פתוח אלק
On 23/09/06, Ilya Konstantinov [EMAIL PROTECTED] wrote: Amos Shapira wrote: Who's the power behind linux.org.il right now? Me. Always been me. (Well, ever since Linux.org.il stopped pointing to IGLU's site.) And what are your thought of what you want to do with this domain name? -- Military justice is to justice what military music is to music = To unsubscribe, send mail to [EMAIL PROTECTED] with the word unsubscribe in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: Login problem
On Sat, 2006-09-23 at 06:25 +0300, Michael Vasiliev wrote: On Saturday September 23 2006 03:31, Amos Shapira wrote: On 23/09/06, Michael Vasiliev [EMAIL PROTECTED] wrote: Not entirely correct, if you have some privileges, namely if you are still a root user inside a chroot padded cell, you can easily break out by moving up a root user can just create a device file and access any device through that, that's why you shouldn't give root access if you don't trust the user of the chroot jail. No points. We weren't discussing that, we discussed how the chroot call works. There are infinite number of things you can do with root access. the tree with fchdir(open(.,O_RDONLY)), followed by a number of chdir(..) and chrooting(.), eventually hitting the /. I think the BSD version of Are you sure? Have you tried this? Actually, I did something like that, about ten years ago. :) But don't tell anyone, ok? ;) Here is what happens at the root of a chroot'ed directory: # ls -ldi . .. 2 drwxr-xr-x 22 root root 624 2006-06-08 17:49 . 2 drwxr-xr-x 22 root root 624 2006-06-08 17:49 .. Same directory outside chroot: # ls -ldi . .. 2 drwxr-xr-x 22 root root 624 2006-06-08 17:49 . 2 drwxr-xr-x 22 root root 4096 2006-08-26 10:25 .. I.e. the chroot environment will simulate the standard practice of /.. == / (the 624 means the they are the same i-node) Ok, they are on the same inode. I never claimed otherwise. And your point is? If the chroot does not set the working directory of the calling program to the chroot one, I don't even need the fchroot call. #include sys/types.h #include sys/stat.h #include unistd.h int main() { int i; mkdir(foo,0755); chroot(foo); for(i=0;i255;i++) { chdir(..); } chroot(.); execl(/bin/sh,-i,NULL); } Works for me... foo / # chroot /chroot /bin/bash bash-3.1# ./bar foo / # ls bin boot chroot dev etc home lib lost+found mnt opt proc root sbin sys tmp usr var foo / # your program is flawed, and you didn't see it because you didn't check any errors in it, neither have you read the man page of 'chroot(2)'. according to the man page, chroot does NOT change the directory. you need to change it explicitly in your code. so your program did not create the so-called root jail properly. if you had added a 'chdir' into the new directory, and then did 'chroot .', then you'd have done your job (more) properly. if you add error printings to your code, you'll see that your last execl fails with 'no such file or directory'. --guy = To unsubscribe, send mail to [EMAIL PROTECTED] with the word unsubscribe in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
WPA encryption using WLAN.
Hey all, I just purchased a new wireless router which supports WPA (64 HEX digits) and a new PCMCIA wireless network adapter (DWL-G650) which supports WPA as well. Now, everything works fine when I use WEP as my encryption method, though, iwconfig won't accept the WPA key: iwconfig ath0 key (64 HEXdigits) -- tells me that thekey is a wrong argument. Is WLAN supports WPA at all? How can I configure my WPA key if it is being supported? Thank you all, Shlomi.
Re: Login problem
On Sat, Sep 23, 2006 at 07:18:38PM +0300, guy keren wrote: foo / # chroot /chroot /bin/bash bash-3.1# ./bar foo / # ls bin boot chroot dev etc home lib lost+found mnt opt proc root sbin sys tmp usr var foo / # your program is flawed, and you didn't see it because you didn't check any errors in it, neither have you read the man page of 'chroot(2)'. according to the man page, chroot does NOT change the directory. you need to change it explicitly in your code. so your program did not create the so-called root jail properly. if you had added a 'chdir' into the new directory, and then did 'chroot .', then you'd have done your job (more) properly. Sigh. His program didn't create a chroot() jail, IT WAS BREAKING OUT OF ONE. Precisely as described in the chroot(2) manual page. Chroot jails are not safe against root. if you add error printings to your code, you'll see that your last execl fails with 'no such file or directory'. Huh? He showed you the output of his program. = To unsubscribe, send mail to [EMAIL PROTECTED] with the word unsubscribe in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: Login problem
On Saturday September 23 2006 19:18, guy keren wrote: On Sat, 2006-09-23 at 06:25 +0300, Michael Vasiliev wrote: On Saturday September 23 2006 03:31, Amos Shapira wrote: On 23/09/06, Michael Vasiliev [EMAIL PROTECTED] wrote: Not entirely correct, if you have some privileges, namely if you are still a root user inside a chroot padded cell, you can easily break out by moving up a root user can just create a device file and access any device through that, that's why you shouldn't give root access if you don't trust the user of the chroot jail. No points. We weren't discussing that, we discussed how the chroot call works. There are infinite number of things you can do with root access. the tree with fchdir(open(.,O_RDONLY)), followed by a number of chdir(..) and chrooting(.), eventually hitting the /. I think the BSD version of Are you sure? Have you tried this? Actually, I did something like that, about ten years ago. :) But don't tell anyone, ok? ;) Here is what happens at the root of a chroot'ed directory: # ls -ldi . .. 2 drwxr-xr-x 22 root root 624 2006-06-08 17:49 . 2 drwxr-xr-x 22 root root 624 2006-06-08 17:49 .. Same directory outside chroot: # ls -ldi . .. 2 drwxr-xr-x 22 root root 624 2006-06-08 17:49 . 2 drwxr-xr-x 22 root root 4096 2006-08-26 10:25 .. I.e. the chroot environment will simulate the standard practice of /.. == / (the 624 means the they are the same i-node) Ok, they are on the same inode. I never claimed otherwise. And your point is? If the chroot does not set the working directory of the calling program to the chroot one, I don't even need the fchroot call. #include sys/types.h #include sys/stat.h #include unistd.h int main() { int i; mkdir(foo,0755); chroot(foo); for(i=0;i255;i++) { chdir(..); } chroot(.); execl(/bin/sh,-i,NULL); } Works for me... foo / # chroot /chroot /bin/bash bash-3.1# ./bar foo / # ls bin boot chroot dev etc home lib lost+found mnt opt proc root sbin sys tmp usr var foo / # your program is flawed, and you didn't see it because you didn't check any errors in it, neither have you read the man page of 'chroot(2)'. For a man your age, you spend too much time under my bed. according to the man page, chroot does NOT change the directory. you need to change it explicitly in your code. so your program did not create the so-called root jail properly. if you had added a 'chdir' into the new directory, and then did 'chroot .', then you'd have done your job (more) properly. The program was never intended to create a root jail, but to escape from one by setting a new root deeper than the working directory, thus effectively placing the wd outside the chroot, and then nothing will prevent me from chdir-ing all the way to the top. Even if you change the working directory of the calling process in your chroot code, I could still escape by adding the code of opening the wd, and fchdir into it to the code above, before the chdirs. It works for me, on my system. It does not have to work as is on yours. How should I know what grsecurity patch you have compiled in? if you add error printings to your code, you'll see that your last execl fails with 'no such file or directory'. Interesting. My original code had the error checks in. I stripped them. No, the execl call did not fail. I am a little bit concerned though, about your claims that you see things that happen on my system. Is it your wild imagination or should I be very, very afraid (TM) ? :) -- Sincerely Yours, Michael Vasiliev Simplicity is prerequisite for reliability. -- Edsger Wybe Dijkstra = To unsubscribe, send mail to [EMAIL PROTECTED] with the word unsubscribe in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: WPA encryption using WLAN.
Hey,Just apt-get install network-manager-gnome. Don't mind the gnome there, the utility works in every desktop and it auto-configures your network. It supports WPA and is on par with Windows' network manager! You get an icon on your system tray which notifies you about available networks and asks you for a password if required when you try to connect to one. Wireless on linux used to be pretty harsh for the end user, so You could say this tool is the Holy Grail of Networking! :DEnjoy :)AlexOn 9/23/06, Shlomi Shalem [EMAIL PROTECTED] wrote: Hey all, I just purchased a new wireless router which supports WPA (64 HEX digits) and a new PCMCIA wireless network adapter (DWL-G650) which supports WPA as well. Now, everything works fine when I use WEP as my encryption method, though, iwconfig won't accept the WPA key: iwconfig ath0 key (64 HEXdigits) -- tells me that thekey is a wrong argument. Is WLAN supports WPA at all? How can I configure my WPA key if it is being supported? Thank you all, Shlomi. -- || Alex Alexander| GlobalStar Interactive Intelligence| visit us @ www.globalstar.gr\
Re: Login problem
On 24/09/06, guy keren [EMAIL PROTECTED] wrote: according to the man page, chroot does NOT change the directory. you need to change it explicitly in your code. so your program did not create the so-called root jail properly. if you had added a 'chdir' into the new directory, and then did 'chroot .', then you'd have done your job (more) properly. Just run this program from inside a root jail and you'll get a shell outside it (e.g. I have an old Sarge partition so I chrooted into it and after running this program I got a shell outside it). The code isn't elegant and the program's success has nothing to do with having a /bin/sh under the chroot jail (because the last step runs /bin/sh from outside the jail) but otherwise his later explenation is accurate. (for instance - the correct loop condition should be to stop when stat(.)==stat(..) which indicates that he reached the real root, and he can probably 'chdir ../../../../../.' in each iteration to speed things up). Cheers, --Amos -- Military justice is to justice what military music is to music = To unsubscribe, send mail to [EMAIL PROTECTED] with the word unsubscribe in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: קוד פתוח אלק
Amos Shapira wrote: On 23/09/06, Ilya Konstantinov [EMAIL PROTECTED] wrote: Amos Shapira wrote: Who's the power behind linux.org.il right now? Me. Always been me. (Well, ever since Linux.org.il stopped pointing to IGLU's site.) And what are your thought of what you want to do with this domain name? Exactly what it is right now -- to be a portal to sites that do a better job than we can. By this, I aim to give all community sites and service providers equal representation, so that nobody would feel we're hagging the domain. In fact, I've always stated this at [ http://www.linux.org.il/about ]. If I understood Danny correctly, his sentiment is caused by the fact there's no 'single point of contact' for Linux on the official domain. Indeed, Linux.org.il doesn't give out that feeling. However, if we flip it around, that'll be misleading to make the community appear different than it really is -- loads of loosely-connected projects who do not report to each other and do not adhere to any common planning, and turn out with stuff we all use day-to-day. Red Hat or Oracle web sites may radiate this 'single point of contact' feel to increase their business, but we shouldn't feel any inferiority complex regarding the big boys and their sites. (You know, the kind of sites which emphasize outside-leading links -- cause, why would you want to go anywhere else?). BTW, surprisingly, even though the site has low goals and requires little investment in content, I've hardly had contributing authors coming up to me with an informative two-paragraph piece in Hebrew on their favorite distro. = To unsubscribe, send mail to [EMAIL PROTECTED] with the word unsubscribe in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]