On 02/19/18 18:55, Edgar Pettijohn wrote:
I'm playing around with the table-socketmap from extras. I stole a simple socket server from beej's networking guide and adjusted it slightly to see what the socketmap would do.

Basically the server just binds to a unix socket and once it gets a connection it prints the recv()'d buffer to stdout. However, smtpd gives a warning:

smtpd[65725]: warn: failure to perform a table lookup on table test

smtpd.conf

table test socketmap:/var/run/sockd.sock

accept from source <test> deliver to mbox

sockmap server output:

laptop$ doas ./sockd -d
new connection on socket 4
socket 4 hung up /* after killing smtpd */

So it is connecting, but doesn't appear to actually send anything.

What could be wrong?


Thanks,

Edgar


It must be a bug. I installed postfix to test it out and here is the results from postmap:

postmap -q "/hello/"socketmap 
<http://www.postfix.org/socketmap_table.html>:unix://var/run/sockd.sock:test The server 
prints: 10:test hello, /I suppose I could have been clearer.  The test with opensmtpd was via 
telnet session.

Reply via email to