Mediator example (wodVPN)
Hi,
I'm using wodVPN COM in Delphi 7.
I want to use my own mediator, on a PC with public IP running windows.
Can you post an example to start and monitoring a mediator?
Thanks in advance ...
Hi,
I'm using wodVPN COM in Delphi 7.
I want to use my own mediator, on a PC with public IP running windows.
Can you post an example to start and monitoring a mediator?
Thanks in advance ...
by wodDamir
, (6673 days ago) @ Valter Sini
Hi Valter,
There is really not much to post. Here is what you should do. Put the following code under a button or in the FormCreate function:
----------------------------------
wodVPNCom1.Mediator.Start(0,8000);
----------------------------------
That code will start the Mediator on port 8000. That's all you need. As for monitoring, you can add the following:
-----------------------------------------------------------------
procedure TForm1.wodVPNCom1MediatorConnected(Sender: TObject;
var IP: OleVariant; Port: Integer; var FromID, ToID, Data,
Allow: OleVariant);
begin
//Add your own code here...
end;
procedure TForm1.wodVPNCom1MediatorDisconnected(Sender: TObject;
var FromID, ToID: OleVariant);
begin
//Add your own code here...
end;
procedure TForm1.wodVPNCom1MediatorExchangeData(Sender: TObject;
var FromID, ToID: OleVariant);
begin
//Add your own code here...
end;
-----------------------------------------------------------------
The last 3 procedures are Events which will enable you monitoring . They will provide you with specific information like the IP the user is connecting, the IP of the user that disconnected etc. Also, the MediatorConnected Event allows you to allow or reject the incoming connection, based on your Allow parameter. If you set it as Allow := False; , the Mediator will deny access to the user.
Hope I helped.
Regards,
Damba
by Valter Sini
, (6667 days ago) @ wodDamir
Thanks a lot ... it was too easy!

Brilliant, even works on the mobile phone...

Thank you very much for the rapid responses. I was a little nervous about dealing with a company that is on a different continent from me. You have proven my concerns to be unfounded.

The people at WeOnlyDo are amazing! ... I always get a super fast response from customer service, and the products are great too. Thanks WeOnlyDo

We have recently completed a large 1200+ location project where reliable Telnet and SSH connectivity was required. wodSSH worked flawlessly and allowed our staff to complete our project ontime and within budget.

The people at WeOnlyDo are amazing! ... I always get a super fast response from customer service, and the products are great too. Thanks WeOnlyDo

Many thanks for your excellent support service. I can see why you have a long list of excellent testimonials on your website.

Count us as a satisfied WeOnlyDo customer. We appreciate your terrific support to get the secure Telnet working properly.

Your support is fantastic.

Count us as a satisfied WeOnlyDo customer. We appreciate your terrific support to get the secure Telnet working properly.

Count us as a satisfied WeOnlyDo customer. We appreciate your terrific support to get the secure Telnet working properly.

