Cisco Systems, Inc.

com.pcube.apps.engage.policy
Class SeAttackApi

java.lang.Object
  extended by com.pcube.apps.engage.policy.SeAttackApi

public class SeAttackApi
extends java.lang.Object


Field Summary
static int ACTION_BLOCK
           
static int ACTION_REPORT
           
static boolean PORT_LIST_TCP
           
static boolean PORT_LIST_UDP
           
 
Constructor Summary
SeAttackApi()
           
 
Method Summary
static void addIpToAcl(com.pcube.management.api.common.Api api, long aclIndex, long ip, long mask)
           
static void addIpv6ToAcl(com.pcube.management.api.common.Api api, long aclIndex, long[] ip, long[] mask)
           
static int findAttackType(com.pcube.management.api.common.Api api, boolean networkSide, boolean attackSource, int protocol, boolean portValid, boolean pairValid)
          Given protocol, side, direction, portValid, and pairValid, tells you what is the attack type.
static com.pcube.management.framework.functionality.Arguments getMinMaxAclIds(com.pcube.management.api.common.Api api)
           
static com.pcube.management.framework.functionality.Arguments getMinMaxDetectorIds(com.pcube.management.api.common.Api api, int slot)
          Tells you the valid range for attack detector IDs on a given slot.
static java.lang.Object getModulesUsingAcl(com.pcube.management.api.common.Api api, int aclIndex, long maxNumModules)
           
static void removeAcl(com.pcube.management.api.common.Api api, long aclIndex)
           
static void resetAllDetectorsToDefault(com.pcube.management.api.common.Api api, int slot)
          Resets all attack detectors to their default configuration.
static void setAttackFilterEnabled(com.pcube.management.api.common.Api api, int slot, boolean enable)
          set the attack filter status.
static void setDetectorAcl(com.pcube.management.api.common.Api api, int slot, long detectorId, long aclIndex)
          Sets the access-list used by a given attack detector.
static void setDetectorAction(com.pcube.management.api.common.Api api, int slot, int detectorId, int attackType, int action)
          Sets the action for a given attack detector for a given detection type.
static void setDetectorAlarm(com.pcube.management.api.common.Api api, int slot, int detectorId, int attackType, boolean alarm)
          Enables/Disables alarm for a given attack detector for a given attack type.
static void setDetectorEnabled(com.pcube.management.api.common.Api api, int slot, int detectorId, boolean enabled)
          Enables/Disables a given attack detector.
static void setDetectorPorts(com.pcube.management.api.common.Api api, int slot, int detectorId, boolean tcp, short[] ports)
          Sets a list of ports for a given attack detector and protocol (TCP/UDP).
static void setDetectorsComment(com.pcube.management.api.common.Api api, int slot, int detectorId, java.lang.String comment)
          Sets the commant for a given attack detector.
static void setDetectorSubNotif(com.pcube.management.api.common.Api api, int slot, int detectorId, int attackType, boolean subNotif)
          Enables/Disables subscriber notification for a given attack detector for a given detection type.
static void setDetectorThresh(com.pcube.management.api.common.Api api, int slot, int detectorId, int attackType, long threshOpenRate, long threshSuspRate, short threshSuspRatio)
          Sets the thresholds for a given attack detector for a given detection type.
static void setEnabled(com.pcube.management.api.common.Api api, int slot, int attackType, boolean enable)
          Enables/Disables a given attack type in this module.
static void setSubNotifPorts(com.pcube.management.api.common.Api api, int slot, int[] ports)
          Resets the subscriber-notification setting for a given attack detector for a given detection type.
static void setSubNotifPorts(com.pcube.management.api.common.Api api, int slot, short[] ports)
          Deprecated.  
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ACTION_BLOCK

public static final int ACTION_BLOCK
See Also:
Constant Field Values

ACTION_REPORT

public static final int ACTION_REPORT
See Also:
Constant Field Values

PORT_LIST_TCP

public static final boolean PORT_LIST_TCP
See Also:
Constant Field Values

PORT_LIST_UDP

public static final boolean PORT_LIST_UDP
See Also:
Constant Field Values
Constructor Detail

SeAttackApi

public SeAttackApi()
Method Detail

findAttackType

public static int findAttackType(com.pcube.management.api.common.Api api,
                                 boolean networkSide,
                                 boolean attackSource,
                                 int protocol,
                                 boolean portValid,
                                 boolean pairValid)
                          throws com.pcube.management.common.WrapperException
Given protocol, side, direction, portValid, and pairValid, tells you what is the attack type.

Parameters:
api -
slot -
networkSide -
attackSource -
protocol -
portValid -
pairValid -
Returns:
Throws:
com.pcube.management.common.WrapperException

getMinMaxDetectorIds

public static com.pcube.management.framework.functionality.Arguments getMinMaxDetectorIds(com.pcube.management.api.common.Api api,
                                                                                          int slot)
                                                                                   throws com.pcube.management.common.WrapperException
Tells you the valid range for attack detector IDs on a given slot.

Parameters:
api -
slot -
Returns:
Argmuents where: OUT uint32 min, desc = "Minimum valid detector ID"; OUT uint32 max, desc = "Maximum valid detector ID";
Throws:
com.pcube.management.common.WrapperException

getMinMaxAclIds

public static com.pcube.management.framework.functionality.Arguments getMinMaxAclIds(com.pcube.management.api.common.Api api)
                                                                              throws com.pcube.management.common.WrapperException
Throws:
com.pcube.management.common.WrapperException

resetAllDetectorsToDefault

public static void resetAllDetectorsToDefault(com.pcube.management.api.common.Api api,
                                              int slot)
                                       throws com.pcube.management.common.WrapperException
Resets all attack detectors to their default configuration.

Parameters:
api -
slot -
Throws:
com.pcube.management.common.WrapperException

setAttackFilterEnabled

public static void setAttackFilterEnabled(com.pcube.management.api.common.Api api,
                                          int slot,
                                          boolean enable)
                                   throws com.pcube.management.common.WrapperException
set the attack filter status.

Parameters:
api -
slot -
enable -
Throws:
com.pcube.management.common.WrapperException

setDetectorAcl

public static void setDetectorAcl(com.pcube.management.api.common.Api api,
                                  int slot,
                                  long detectorId,
                                  long aclIndex)
                           throws com.pcube.management.common.WrapperException
Sets the access-list used by a given attack detector.

Parameters:
api -
slot -
detectorId -
aclIndex -
Throws:
com.pcube.management.common.WrapperException

setDetectorAction

public static void setDetectorAction(com.pcube.management.api.common.Api api,
                                     int slot,
                                     int detectorId,
                                     int attackType,
                                     int action)
                              throws com.pcube.management.common.WrapperException
Sets the action for a given attack detector for a given detection type.

Parameters:
api -
slot -
detectorId -
attackType -
action -
Throws:
com.pcube.management.common.WrapperException

setDetectorAlarm

public static void setDetectorAlarm(com.pcube.management.api.common.Api api,
                                    int slot,
                                    int detectorId,
                                    int attackType,
                                    boolean alarm)
                             throws com.pcube.management.common.WrapperException
Enables/Disables alarm for a given attack detector for a given attack type.

Parameters:
api -
slot -
detectorId -
attackType -
alarm -
Throws:
com.pcube.management.common.WrapperException

setDetectorEnabled

public static void setDetectorEnabled(com.pcube.management.api.common.Api api,
                                      int slot,
                                      int detectorId,
                                      boolean enabled)
                               throws com.pcube.management.common.WrapperException
Enables/Disables a given attack detector.

Parameters:
api -
slot -
detectorId -
enabled -
Throws:
com.pcube.management.common.WrapperException

setDetectorPorts

public static void setDetectorPorts(com.pcube.management.api.common.Api api,
                                    int slot,
                                    int detectorId,
                                    boolean tcp,
                                    short[] ports)
                             throws com.pcube.management.common.WrapperException
Sets a list of ports for a given attack detector and protocol (TCP/UDP). The list will replace any existing list, if configured. Use an empty list to remove currently configured ports. Up to 15 ports can be configured for each protocol (TCP and UDP).

Parameters:
api -
slot -
detectorId -
tcp -
ports -
Throws:
com.pcube.management.common.WrapperException

setDetectorsComment

public static void setDetectorsComment(com.pcube.management.api.common.Api api,
                                       int slot,
                                       int detectorId,
                                       java.lang.String comment)
                                throws com.pcube.management.common.WrapperException
Sets the commant for a given attack detector.

Parameters:
api -
slot -
detectorId -
comment -
Throws:
com.pcube.management.common.WrapperException

setDetectorSubNotif

public static void setDetectorSubNotif(com.pcube.management.api.common.Api api,
                                       int slot,
                                       int detectorId,
                                       int attackType,
                                       boolean subNotif)
                                throws com.pcube.management.common.WrapperException
Enables/Disables subscriber notification for a given attack detector for a given detection type.

Parameters:
api -
slot -
detectorId -
attackType -
subNotif -
Throws:
com.pcube.management.common.WrapperException

setDetectorThresh

public static void setDetectorThresh(com.pcube.management.api.common.Api api,
                                     int slot,
                                     int detectorId,
                                     int attackType,
                                     long threshOpenRate,
                                     long threshSuspRate,
                                     short threshSuspRatio)
                              throws com.pcube.management.common.WrapperException
Sets the thresholds for a given attack detector for a given detection type.

Parameters:
api -
slot -
detectorId -
attackType -
threshOpenRate -
threshSuspRate -
threshSuspRatio -
Throws:
com.pcube.management.common.WrapperException

setEnabled

public static void setEnabled(com.pcube.management.api.common.Api api,
                              int slot,
                              int attackType,
                              boolean enable)
                       throws com.pcube.management.common.WrapperException
Enables/Disables a given attack type in this module.

Parameters:
api -
slot -
attackType -
enable -
Throws:
com.pcube.management.common.WrapperException

setSubNotifPorts

public static void setSubNotifPorts(com.pcube.management.api.common.Api api,
                                    int slot,
                                    short[] ports)
                             throws com.pcube.management.common.WrapperException
Deprecated. 

Resets the subscriber-notification setting for a given attack detector for a given detection type.

Parameters:
api -
slot -
ports -
Throws:
com.pcube.management.common.WrapperException

setSubNotifPorts

public static void setSubNotifPorts(com.pcube.management.api.common.Api api,
                                    int slot,
                                    int[] ports)
                             throws com.pcube.management.common.WrapperException
Resets the subscriber-notification setting for a given attack detector for a given detection type.

Parameters:
api -
slot -
ports -
Throws:
com.pcube.management.common.WrapperException

getModulesUsingAcl

public static java.lang.Object getModulesUsingAcl(com.pcube.management.api.common.Api api,
                                                  int aclIndex,
                                                  long maxNumModules)
                                           throws com.pcube.management.common.WrapperException
Throws:
com.pcube.management.common.WrapperException

removeAcl

public static void removeAcl(com.pcube.management.api.common.Api api,
                             long aclIndex)
                      throws com.pcube.management.common.WrapperException
Throws:
com.pcube.management.common.WrapperException

addIpToAcl

public static void addIpToAcl(com.pcube.management.api.common.Api api,
                              long aclIndex,
                              long ip,
                              long mask)
                       throws com.pcube.management.common.WrapperException
Throws:
com.pcube.management.common.WrapperException

addIpv6ToAcl

public static void addIpv6ToAcl(com.pcube.management.api.common.Api api,
                                long aclIndex,
                                long[] ip,
                                long[] mask)
                         throws com.pcube.management.common.WrapperException
Throws:
com.pcube.management.common.WrapperException

Cisco Systems, Inc.

Copyright © 2013 Cisco Systems, Inc. Confidential.