Re: png to pdf
On Sun, Jul 11, 2004 at 07:34:41PM +0300, Kfir Lavi wrote: > Yedidyah Bar-David wrote: > >Also imgtops, which most of the time will create smaller and faster > >files. I did not try it myself, nor did I try to filter the output > >through ps2pdf. > tnx, > i have used convert -append to make a 4 A4 letters that i scaned, to one > image file. This is good and very easy for the other side to get it. > about the imgtops, isn't png's algorithm the same for all programs?! so > how it can compress it better? You didn't ask for xxxtopng, but xxxtopdf. So what counts isn't png's algorithm, but pdf's. While I didn't check pdf specifically, ps (which behaves close in these things) has a few ways to keep trivial, non- compressed bitmaps, and also has builtin the algorithms for some formats (jpeg, and I think png/gif). But most programs, convert included, do not know about this, and use only the trivial uncompressed bitmap. imgtops knows about the "advanced" features of ps and uses them. One more note: If it's for black/white (or blue/white (of a pen)) pages, the best I can recommend (takes some work, but is very good) is the following: 1. Scan in very high quality (600dpi or more, 8bit grayscale or 24bit). 2. Convert to pgm however you like (e.g. with convert). 3. Smooth with potrace. It's a very nice little program. Use '-g' to output pgm. 4. Convert to pbm with pgmtopbm -threshold -value 0.5 (or change 0.5 if it's too light or too dark). 5. Convert to g4 tiff (very efficient black/white lossless compression) with pnmtotiff -g4. 6. Collect to a single tiff with tiffcp. 7. Convert to pdf with tiff2pdf. Since pdf knows about g4, it won't take time, be very small, and hopefully (depending on source) of very high quality. I already saw there is a gui for potrace, and maybe one day I'll try to add this script to it. -- Didi = 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]
retrieving network interface information
Title: retrieving network interface information Hi. I have a server (kernel 2.4.20) with a network card and a cellular modem. On that server I run an application That waits for incoming connections on a known port. It is important to me to know to which Network Interface (in this case ppp0 and eth0) each incoming connection belongs to. How do I do it? I know the Solution involves the usage of ioctl() , but the documentation I found about this issue is very scarce. I would appreciate any idea (sample source code could be Even better J). Thanks.
Free Redhat 9 updates ?
Assume that I would like to continue my status of a free Redhat rider, and that I cannot convert to Fedora, yet I would like to receive frequent, reliable, security updates. Does anyone have recommendations for a specific RPM repository that allows for that? I managed to dig www.whiteboxlinux.org out of rusting memory. Is it good for my purposes? Are there better ones? Thank! -- Dan Kenigsberghttp://www.cs.technion.ac.il/~dankenICQ 162180901 = 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: Free Redhat 9 updates ?
Hi Dan, On Mon, 12 Jul 2004 13:02:01 +0300, Dan Kenigsberg > > Does anyone have recommendations for a specific RPM repository that allows for > that? > There's the fedoralegacy project : http://www.fedoralegacy.org/ It deals with rh72,rh73,rh8 and rh9 and it's free as you've required... Better quality speed and reliabilty can be found through the progeny transition service: http://www.progeny.com/products/transition.html This service cost around 5$ a month but from my experience is faster and more reliable ... Lior. = 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: Free Redhat 9 updates ?
Dan Kenigsberg wrote: Assume that I would like to continue my status of a free Redhat rider, and that I cannot convert to Fedora, yet I would like to receive frequent, reliable, security updates. Does anyone have recommendations for a specific RPM repository that allows for that? I managed to dig www.whiteboxlinux.org out of rusting memory. Is it good for my purposes? Are there better ones? Thank! You can try the Fedora legacy project: http://whatsup.org.il/article/2803 http://fedoralegacy.org/ Cheers -- Meir Kriheli http://mksoft.co.il = 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]
For every debian user that have problem with glibc
Hi list, Since yearstoday debian fixed all the glibc problems that we encountered for the past month +. So upgrade the system if you have any problem with it. Ido -- "Well-timed silence hath more eloquence than speech." -- Martin Fraquhar Tupper = 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: retrieving network interface information
Hello Gershon , I assume these interfaces have a different IP addresses. netstat -a shows the IP addresses on which you have opened sockets ; so it seems to me you can deduce from this to which interface each socket belongs. Is it good enough for you ? Or must you do it a program , using ioctl() calls? regards, Rami Rosen _ Add photos to your messages with MSN 8. Get 2 months FREE*. http://join.msn.com/?page=features/featuredemail = 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]
socket shutdown and friends
Howdie, Someone (i think it was Shachar) asked about shutdown and loosing messages - well, I jsut came across the SO_LINGER socket options (man 7 socket) and though it can help: " SO_LINGER Sets or gets the SO_LINGER option. The argument is a linger structure. struct linger { int l_onoff;/* linger active */ int l_linger; /* how many seconds to linger for */ }; When enabled, a close(2) or shutdown(2) will not return until all queued messages for the socket have been successfully sent or the linger timeout has been reached. Otherwise, the call returns immediately and the closing is done in the background. When the socket is closed as part of exit(2), it always lingers in the background. " Cheers, Gilad -- Gilad Ben-Yossef <[EMAIL PROTECTED]> Codefidence. A name you can trust(TM) Tel: +972.9.8650475 ext. 201, Fax: +972.9.8850643 http://www.codefidence.com = 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: retrieving network interface information
On Monday 12 July 2004 13:08, Gershon Geva wrote: > I have a server (kernel 2.4.20) with a network card and a > cellular modem. On that server I run an application > That waits for incoming connections on a known port. It is > important to me to know to which > Network Interface (in this case ppp0 and eth0) each incoming connection > belongs to. > How do I do it? I know the Solution involves the usage of ioctl() , but > the documentation > I found about this issue is very scarce. I would appreciate any idea > (sample source code could be > Even better :-)). Actually, what you are asking for is impossbile. Oh, the kernel knows each packet came through which interface, but this doesn't have to be the same for each packet! This is why a socket has no underlying "device", unless you specifically chose to bind it to one. Things you can do are: 1) Use the information returned by the accept() call to know the IP for the other side of the connection and decide according to that, in addition to using firewalling rules (iptables) to limit from where packets with certain source address can show up. 2) Create two sockets to listen to, one for each device and then use the SO_BINDTODEVICE socket option to make each one bound to one of the devices. From "man 7 socket": SO_BINDTODEVICE Bind this socket to a particular device like ×âÅeth0×âÂ, as speci- fied in the passed interface name. If the name is an empty string or the option length is zero, the socket device binding is removed. The passed option is a variable-length null termi- nated interface name string with the maximum size of IFNAMSIZ. If a socket is bound to an interface, only packets received from that particular interface are processed by the socket. Note that this only works for some socket types, particularly AF_INET sockets. It is not supported for packet sockets (use normal bind(8) there). Hope this helps, Gilad -- Gilad Ben-Yossef <[EMAIL PROTECTED]> Codefidence. A name you can trust(TM) Tel: +972.9.8650475 ext. 201, Fax: +972.9.8850643 http://www.codefidence.com 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: socket shutdown and friends
Gilad Ben-Yossef wrote: Howdie, Someone (i think it was Shachar) asked about shutdown and loosing messages - well, I jsut came across the SO_LINGER socket options (man 7 socket) and though it can help: " SO_LINGER Sets or gets the SO_LINGER option. The argument is a linger structure. struct linger { int l_onoff;/* linger active */ int l_linger; /* how many seconds to linger for */ }; When enabled, a close(2) or shutdown(2) will not return until all queued messages for the socket have been successfully sent or the linger timeout has been reached. Otherwise, the call returns immediately and the closing is done in the background. When the socket is closed as part of exit(2), it always lingers in the background. " Cheers, Gilad That does not solve my problem, as the whole purpose of the program was to do things asynchronously. Making shutdown block is not an option. Thanks anyways, though. Shachar -- Shachar Shemesh Lingnu Open Source Consulting ltd. http://www.lingnu.com/ = 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]
[OT] php3 app on php4
hi gang. I'm in an unknown territory and I'm sure one of you can help... since this is a bit off-topic you can answer me off list. I recently moved to a new server, with newer needs and thus updated software. the one thing that broke on the move from php3 to php4 was the IMP webmail client. I have installed IMP3 next to it, but some of my users must have something IMP 2.2.6 has - the ability to change their "from" address for different recipients, like I do with my domain. I hoped the only thing necessary would be to add this to my Apache's conf: AddType application/x-httpd-php .php3 and the PHP4 engine would parse the pages, but apperently it's broken... I get a blank page with no errors. has anyone got a clue? much appreciated, Ira. -- The little prince Ira Abramov http://ira.abramov.org/email/ = 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: socket shutdown and friends
Shachar Shemesh wrote: Gilad Ben-Yossef wrote: [... stuff about SO_LINGER was snipped ...] That does not solve my problem, as the whole purpose of the program was to do things asynchronously. Making shutdown block is not an option. Is there any reason why you cannot start another thread, and close the socket in that thread (and if necessary - do all your socket work there)? --- Omer My own blog is at http://www.livejournal.com/users/tddpirate/ My opinions, as expressed in this E-mail message, are mine alone. They do not represent the official policy of any organization with which I may be affiliated in any way. WARNING TO SPAMMERS: at http://www.zak.co.il/spamwarning.html = 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]
HTTP body capture with LiveHTTP Headers ?
I've been using http://livehttpheaders.mozdev.org/ for quite awhile now, whenever I needed to understand a naughty web site. I know that the name of the package suggests otherwise, but does anyone here knows if I can capture the bodies of HTTP requests/responses too? This would be even more helpful when it's HTTPS. I know that I have the code, and could change it myself in principle, but the relationship of me and chrome is a series of failures. :( -- Dan Kenigsberghttp://www.cs.technion.ac.il/~dankenICQ 162180901 = 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: HTTP body capture with LiveHTTP Headers ?
Dan Kenigsberg wrote: I've been using http://livehttpheaders.mozdev.org/ for quite awhile now, whenever I needed to understand a naughty web site. I know that the name of the package suggests otherwise, but does anyone here knows if I can capture the bodies of HTTP requests/responses too? This would be even more helpful when it's HTTPS. I know that I have the code, and could change it myself in principle, but the relationship of me and chrome is a series of failures. :( Install eclipse 2.x and the solex plugin ( http://solex.sourceforge.net/ ). It lets you capture the entire session, headers & bodies. It also lets you replay it. It works by serving as a proxy for the browser (whatever browser you use). HTH, Arnon = 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: [OT] php3 app on php4
On Mon, 12 Jul 2004 18:19:18 +0300, Ira Abramov <[EMAIL PROTECTED]> wrote: > I hoped the only thing necessary would be to add this to my Apache's > conf: > AddType application/x-httpd-php .php3 > and the PHP4 engine would parse the pages, but apperently it's broken... > I get a blank page with no errors. > > has anyone got a clue? Is it really a blank page? try doing a "view source", my guess is that you will see the PHP code there, which means the PHP code isn't interpreted. Does it work with normal PHP files (*.php)? if yes, the AddType line is sufficient. If not - you probably forgot to load the module (using the LoadModule/AddModule directives). Oh and ofcourse, did you restart apache? > much appreciated, > Ira. Sagi = 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: HTTP body capture with LiveHTTP Headers ?
> Install eclipse 2.x and the solex plugin ( http://solex.sourceforge.net/ ). > It lets you capture the entire session, headers & bodies. It also lets > you replay it. > It works by serving as a proxy for the browser (whatever browser you use). I believe that a proxy cannot see what's going on inside an HTTPS session, and therefore such tool is of lesser value for me. But thank you. -- Dan Kenigsberghttp://www.cs.technion.ac.il/~dankenICQ 162180901 = 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]
[AUG PENG 2004] key signing party
As part of August Penguin 2004, we will be having a key signing party once again. Details available here: http://august.penguin.org.il/key.html For the impatient: send me your public key, key ID and fingerprint, expect a confirmation that it has been received, and show up to the event. See you there! Cheers, Muli -- Muli Ben-Yehuda http://www.mulix.org | http://mulix.livejournal.com/ signature.asc Description: Digital signature
Re: HTTP body capture with LiveHTTP Headers ?
Quoting Dan Kenigsberg, from the post of Mon, 12 Jul: > I've been using http://livehttpheaders.mozdev.org/ for quite awhile now, > whenever I needed to understand a naughty web site. > > I know that the name of the package suggests otherwise, but does anyone here > knows if I can capture the bodies of HTTP requests/responses too? This would be > even more helpful when it's HTTPS. > > I know that I have the code, and could change it myself in principle, but the > relationship of me and chrome is a series of failures. :( you could probably record the entire stream of an HTTP session by using netcat as a "proxy". however for SSL sessions you need to know the server key. Mercury has a product that does that, it was developped by one Adi Stav who is probably not on the list these days. he was thinking about rewriting this code under GPL but this has not happend yet AFAIK. -- so unique it hurts Ira Abramov http://ira.abramov.org/email/ = 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: socket shutdown and friends
On Mon, 12 Jul 2004 16:24:10 +0300, Shachar Shemesh <[EMAIL PROTECTED]> wrote: Gilad Ben-Yossef wrote: Howdie, Someone (i think it was Shachar) asked about shutdown and loosing messages - well, I jsut came across the SO_LINGER socket options (man 7 socket) and though it can help: " SO_LINGER Sets or gets the SO_LINGER option. The argument is a linger structure. struct linger { int l_onoff;/* linger active */ int l_linger; /* how many seconds to linger for */ }; When enabled, a close(2) or shutdown(2) will not return until all queued messages for the socket have been successfully sent or the linger timeout has been reached. Otherwise, the call returns immediately and the closing is done in the background. When the socket is closed as part of exit(2), it always lingers in the background. " Cheers, Gilad That does not solve my problem, as the whole purpose of the program was to do things asynchronously. Making shutdown block is not an option. Thanks anyways, though. Shachar Hi all, Shachar, I've missed the thread where you describe what your problem is and I can't seem to find it in the Linux-IL archive. I'm actually quite curious about the problem (as always about network programming). If it would bother others perhaps you could send me the problem description privately. Eli -- Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/ = 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: retrieving network interface information
On Mon, 12 Jul 2004 12:08:48 +0200, Gershon Geva <[EMAIL PROTECTED]> wrote: Hi. I have a server (kernel 2.4.20) with a network card and a cellular modem. On that server I run an application That waits for incoming connections on a known port. It is important to me to know to which Network Interface (in this case ppp0 and eth0) each incoming connection belongs to. How do I do it? I know the Solution involves the usage of ioctl() , but the documentation I found about this issue is very scarce. I would appreciate any idea (sample source code could be Even better :-)). Thanks. I'll suggest the following steps (mind you there are a LOT of small details to cover though): 1. Enumerate all interfaces on your server using ioctl's interface option SIOCGIFCONF. It's not trivial to cover all aspects of all interfaces as Stevens clearly shows in his full-blown code that does this exact thing :) The code is in UNIX network programming in the ioctl chapter. I'd suggest AGAINST using it as it's exceedingly long and annoying. (much to learn from it though). Once this is done, keep the IP addresses of all your interfaces in whatever way you prefer. For IPv4 you can just save an array of in_addr types (along with names if you prefer..) 2. When a new connection is establihed, call getsockname to retrieve the IP address of the local end of the connection. 3. Look up the IP you got from step 2 in the array from ioctl(). Since the connection arrived on one of the interfaces, one must match and that is the interface you were looking for. Eli -- Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/ = 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: HTTP body capture with LiveHTTP Headers ?
On Mon, Jul 12, 2004, Ira Abramov wrote about "Re: HTTP body capture with LiveHTTP Headers ?": > you could probably record the entire stream of an HTTP session by using > netcat as a "proxy". however for SSL sessions you need to know the > server key. Mercury has a product that does that, it was developped by > one Adi Stav who is probably not on the list these days. he was thinking > about rewriting this code under GPL but this has not happend yet AFAIK. The product you describe might be useful while debugging the *server*, when you might have a copy of its key. It is not very useful when you're trying to debug a client (e.g., develop a script which automates the use of some site), and you don't have a key. A proxy-like solution can be used, however: the proxy can act as a terminator for both sides, checking the authenticity of the server, but presenting its own key to the client. In this case the client needs to recognize this proxy key as a valid one (for all sites), but this should be easy to do. I don't know if any available web-proxies can be easily set up to perform this sort of "man in the middle" task. -- Nadav Har'El| Tuesday, Jul 13 2004, 24 Tammuz 5764 [EMAIL PROTECTED] |- Phone +972-523-790466, ICQ 13349191 |Attention: There will be a rain dance http://nadav.harel.org.il |Friday night, weather permitting. = 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: [OT] php3 app on php4
Does your php engine work [== does any php script work]? Vitaly *** Information contained in this email message is intended only for use of the individual or entity named above. If the reader of this message is not the intended recipient, or the employee or agent responsible to deliver it to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communication in error, please immediately notify the [EMAIL PROTECTED] and destroy the original message. *** 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]