although i'm having trouble figuring out exactly what your asking

note that there is no 100% accurate way to know if a user is connected via a socket script or by a real client, this is because a socket script can be coded to perfectly emulate a client, it could make you think it was anythign it wanted.

you see, clients use 'sockets' to connect also, its just hard coded, rather than scripted .. its all the same kind of connection ( TCP )

there are a few things you could try .. but anyone wanting to get around them easily could...

Cobra^