Re: about connect



Hello,

There's only one - socketcall - the others are subfunctions, determined
by the "call" in %ebx. "man 2 socketcall" basically tells you not to use
it, but gives a brief description.

Thanks, I've solved that, got some manual pages missing in here. As you
say I think all is gonna be arround socketcall. Although it says it's
specific to linux and shouldn't be used, as you point out.

The 102 goes in %eax, one of the others in %ebx - just like you've got
it... What does your code return? Well maybe I'll try it and get back to
you... I'm not sure where you need to go next. "bind" may not apply to
AF_INET(?). Maybe "connect"? Looks like the "args" structure for that
includes a pointer to another structure... (sockaddr)...

execve("./smtp", ["./smtp"], [/* 28 vars */]) = 0
socket(PF_INET, SOCK_STREAM, IPPROTO_TCP) = 3
_exit(0) = ?

It exits succesfully, I've been also trying playing arround the
server's code, but as I expected, if I call bind on 127.0.0.1 port 25 I
get a `permission denied' alike message, and other calls depends on a
socket binded and listening.

What I've done is to send a post to comp.protocols.tcpip for if anybody
want's to give me some sort of overview, so I can understand what the
procedure should be. I don't seem to be clever enough to find out by
myself, although haven't given up on trying.

Look around that SF site for Scott Lanning's "daytime" client. Not
quite what you're doing, but it might give you some ideas. In order to
get my Nasm translation to work, I had to fire up a daytime server on my
loopback connection. Required a minor edit to /etc/inetd.conf, as I
recall. The utilities in "asmutils" probably have an example of what
you're trying to do, too - Nasm syntax, though...

Didn't see the daytime server, but I'll be looking to asmutils now

Obviously, this would be something very handy to be able to do, so I
hope you'll have good luck with it!

Yes it would, quite interesting network programming.

Whilst doing the c code, I managed to get into my email account and
send messages to myself or other emails accounts,. Also found out that
`wget' is nothing but a "GET THE_URI HTTP..", so I could end up by
having an independent bug-report system, available whilst the user has
got internet access.

The thing is I couldn't do it without having to use mimencode and
logging into the respective email account, so I guess isn't a proper
reliable way. Whilst all the smtp servers I found would relay if doing
telnet by hand, none of them worked when compiling and executing the
program without logging first, and some of them not even doing it.

In the worst case one could setup an email account just for that, and
if anybody bothers exploding it, all that is needed is another account,
or setting up an old machine for that.

Where I live, the local council provides free web-access email, maybe I
could talk to them in a future to see whether they would enable an
account that would relay email without needeing to authenticate for me.
Would really like to see how would this work in practice.

Kind Regards,

.