Adding an IP Access IP Mask for a Client (AddIPAccessRule)

Use the ICIClientSettings interface AddIPAccessRule method to add the allowed or denied IP mask from which the client is allowed to connect. Refer to User IP Access Ban List for an illustration of how this and other Client Settings Interface Methods and Properties can be accessed in the Administrator interface.

icon_info.gif

This method is available in EFT Server 5.1.1 and later.

Signature:

In EFT Server versions 5.1.1 to 6.0.x:

HRESULT AddIPAcessRule([in] long val);

In EFT Server v6.1 and later:

HRESULT AddIPAcessRule(bstrMask As String, bAllow As Boolean);

For example, the following VBScript code assigns only the 1.1.1.1 IP address to a client (in EFT Server v6.1 and later):

client.SetLimitAccessByIP True ‘turn Limit Access by IP on

client.IPAccessAllowedDefault = False ‘forbid all IPs except for...

For Each mask In client.GetAllowedMasks ‘Remove old ‘Allowed’ IPs

client.RemoveIPAccessRule mask, True

Next

client.AddIPAccessRule "1.1.1.1", True ‘Assign ‘Allowed ’IP

 

Did this topic solve your problem/answer your question?

- For the most up-to-date information regarding EFT Server and its modules;

- To view version history, updates, and activation instructions;

- To download a PDF of this user guide;

- And to search the Knowledgebase and User Forum,

Visit the GlobalSCAPE Support Center, http://www.globalscape.com/support.

Refer to the About dialog box for copyright information.

Last modified: 14-Sep-10 at 17:45:05