d1kGroup
asked on
copture all incoming net send messeges!
how i can capture all incoming messeges sended with "net send" command under nt platform?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
i look in msdn an NetAlertRaise and it's look to be what i need but is not NetAPI32.dcu in delphi! can you give me a header of NetAPI.dll???
or (better) a simple delphi example!!!
d1k
or (better) a simple delphi example!!!
d1k
ASKER
no more need header for netapi.dll!!
i found it!! it's call lm!!!
i found it!! it's call lm!!!
K, let me know if you need anymore help!
Shane
Shane
ASKER
i tryed NetAlertRaise but not working...
pls give a simple example!!!
d1k
pls give a simple example!!!
d1k
You tried it that quick!
Shane
Shane
ASKER
i just translate the msdn example!!!
d1k
d1k
please post me what you used for code...
ANd I will look
Shane
ANd I will look
Shane
ASKER
Shane, here is the code i tried:
const
VAREDSIZE = 312;
type
TPUSER_OTHER_INFO = record
alrtus_errcode: Integer;
alrtus_numstrings: Integer;
end;
var
buf: array [0..VAREDSIZE] of char;
pUserInfo: ^TPUSER_OTHER_INFO;
begin
FreeMem(pUserInfo, VAREDSIZE);
pUserInfo.alrtus_errcode := -1;
pUserInfo.alrtus_numstring s := 1;
if NetAlertRaiseEx(ALERT_MESS AGE_EVENT, pUserInfo, 255, 'netsvcs') = NERR_Success then begin
ShowMessage('something is coming!!!');
end;
d1k
const
VAREDSIZE = 312;
type
TPUSER_OTHER_INFO = record
alrtus_errcode: Integer;
alrtus_numstrings: Integer;
end;
var
buf: array [0..VAREDSIZE] of char;
pUserInfo: ^TPUSER_OTHER_INFO;
begin
FreeMem(pUserInfo, VAREDSIZE);
pUserInfo.alrtus_errcode := -1;
pUserInfo.alrtus_numstring
if NetAlertRaiseEx(ALERT_MESS
ShowMessage('something is coming!!!');
end;
d1k
ASKER
i forgot to mention that it raise an exception!!!
prb service is not called netsvcs... but how???
prb service is not called netsvcs... but how???
ASKER
i tried too
NetAlertRaiseEx(ALERT_MESS AGE_EVENT, pUserInfo, VAREDSIZE, 'svchost.exe')
but it raise the same exception!!!
NetAlertRaiseEx(ALERT_MESS
but it raise the same exception!!!
You need mail slot component. Download some of them from here :
http://swiss.torry.net/lan_comms.htm
I use Mailslot v.1.1 - you just install it, drop on the form and write you code in OnNewMessage event...
ASKER
i try all mail slots components from torry.net but noone capture messeges sended with "net send"!!!
d1k
d1k
ASKER
more info: i don't want a replacer for Messenger service... i junst want to capture all incoming messeges!!!!
d1k
d1k
Shane