id
int32
0
165k
repo
stringlengths
7
58
path
stringlengths
12
218
func_name
stringlengths
3
140
original_string
stringlengths
73
34.1k
language
stringclasses
1 value
code
stringlengths
73
34.1k
code_tokens
list
docstring
stringlengths
3
16k
docstring_tokens
list
sha
stringlengths
40
40
url
stringlengths
105
339
129,400
zaproxy/zaproxy
src/org/parosproxy/paros/model/SiteMap.java
SiteMap.handleEvent
private void handleEvent(SiteNode parent, SiteNode node, EventType eventType) { switch (eventType) { case ADD: publishEvent(SiteMapEventPublisher.SITE_NODE_ADDED_EVENT, node); if (parent == getRoot()) { publishEvent(SiteMapEventPublisher.SITE_ADDED_EVENT, node); } break; case REMOVE: p...
java
private void handleEvent(SiteNode parent, SiteNode node, EventType eventType) { switch (eventType) { case ADD: publishEvent(SiteMapEventPublisher.SITE_NODE_ADDED_EVENT, node); if (parent == getRoot()) { publishEvent(SiteMapEventPublisher.SITE_ADDED_EVENT, node); } break; case REMOVE: p...
[ "private", "void", "handleEvent", "(", "SiteNode", "parent", ",", "SiteNode", "node", ",", "EventType", "eventType", ")", "{", "switch", "(", "eventType", ")", "{", "case", "ADD", ":", "publishEvent", "(", "SiteMapEventPublisher", ".", "SITE_NODE_ADDED_EVENT", "...
Handles the publishing of the add or remove event. Node events are always published. Site events are only published when the parent of the node is the root of the tree. @param parent relevant parent node @param node the site node the action is being carried out for @param eventType the type of event occurring (ADD or ...
[ "Handles", "the", "publishing", "of", "the", "add", "or", "remove", "event", ".", "Node", "events", "are", "always", "published", ".", "Site", "events", "are", "only", "published", "when", "the", "parent", "of", "the", "node", "is", "the", "root", "of", ...
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/model/SiteMap.java#L812-L826
129,401
zaproxy/zaproxy
src/org/parosproxy/paros/model/SiteMap.java
SiteMap.publishEvent
private static void publishEvent(String event, SiteNode node) { ZAP.getEventBus().publishSyncEvent(SiteMapEventPublisher.getPublisher(), new Event(SiteMapEventPublisher.getPublisher(), event, new Target(node))); }
java
private static void publishEvent(String event, SiteNode node) { ZAP.getEventBus().publishSyncEvent(SiteMapEventPublisher.getPublisher(), new Event(SiteMapEventPublisher.getPublisher(), event, new Target(node))); }
[ "private", "static", "void", "publishEvent", "(", "String", "event", ",", "SiteNode", "node", ")", "{", "ZAP", ".", "getEventBus", "(", ")", ".", "publishSyncEvent", "(", "SiteMapEventPublisher", ".", "getPublisher", "(", ")", ",", "new", "Event", "(", "Site...
Publish the event being carried out. @param event the event that is happening @param node the node being acted upon @since 2.5.0
[ "Publish", "the", "event", "being", "carried", "out", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/model/SiteMap.java#L835-L837
129,402
zaproxy/zaproxy
src/org/zaproxy/zap/extension/ascan/PolicyAllCategoryPanel.java
PolicyAllCategoryPanel.reloadPolicies
public void reloadPolicies(String scanPolicyName) { DefaultComboBoxModel<String> policies = new DefaultComboBoxModel<>(); for (String policy : extension.getPolicyManager().getAllPolicyNames()) { policies.addElement(policy); } getPolicySelector().setModel(policies); ...
java
public void reloadPolicies(String scanPolicyName) { DefaultComboBoxModel<String> policies = new DefaultComboBoxModel<>(); for (String policy : extension.getPolicyManager().getAllPolicyNames()) { policies.addElement(policy); } getPolicySelector().setModel(policies); ...
[ "public", "void", "reloadPolicies", "(", "String", "scanPolicyName", ")", "{", "DefaultComboBoxModel", "<", "String", ">", "policies", "=", "new", "DefaultComboBoxModel", "<>", "(", ")", ";", "for", "(", "String", "policy", ":", "extension", ".", "getPolicyManag...
Reloads the scan policies, which will pick any new ones that have been defined and selects the policy with the given name. @param scanPolicyName the name of the policy that should be selected @since 2.5.0
[ "Reloads", "the", "scan", "policies", "which", "will", "pick", "any", "new", "ones", "that", "have", "been", "defined", "and", "selects", "the", "policy", "with", "the", "given", "name", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/ascan/PolicyAllCategoryPanel.java#L247-L254
129,403
zaproxy/zaproxy
src/org/zaproxy/zap/view/ContextGeneralPanel.java
ContextGeneralPanel.getTxtDescription
private ZapTextArea getTxtDescription() { if (txtDescription == null) { txtDescription = new ZapTextArea(); txtDescription.setBorder(javax.swing.BorderFactory .createBevelBorder(javax.swing.border.BevelBorder.LOWERED)); txtDescription.setLineWrap(true); } return txtDescription; }
java
private ZapTextArea getTxtDescription() { if (txtDescription == null) { txtDescription = new ZapTextArea(); txtDescription.setBorder(javax.swing.BorderFactory .createBevelBorder(javax.swing.border.BevelBorder.LOWERED)); txtDescription.setLineWrap(true); } return txtDescription; }
[ "private", "ZapTextArea", "getTxtDescription", "(", ")", "{", "if", "(", "txtDescription", "==", "null", ")", "{", "txtDescription", "=", "new", "ZapTextArea", "(", ")", ";", "txtDescription", ".", "setBorder", "(", "javax", ".", "swing", ".", "BorderFactory",...
This method initializes txtDescription @return org.zaproxy.zap.utils.ZapTextArea
[ "This", "method", "initializes", "txtDescription" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/view/ContextGeneralPanel.java#L112-L120
129,404
zaproxy/zaproxy
src/org/zaproxy/zap/extension/ascan/CustomScanDialog.java
CustomScanDialog.save
@Override public void save() { List<Object> contextSpecificObjects = new ArrayList<Object>(); techTreeState = getTechTree().getTechSet(); if (!this.getBoolValue(FIELD_ADVANCED)) { contextSpecificObjects.add(scanPolicy); } else { contextSpecificObjects.add(po...
java
@Override public void save() { List<Object> contextSpecificObjects = new ArrayList<Object>(); techTreeState = getTechTree().getTechSet(); if (!this.getBoolValue(FIELD_ADVANCED)) { contextSpecificObjects.add(scanPolicy); } else { contextSpecificObjects.add(po...
[ "@", "Override", "public", "void", "save", "(", ")", "{", "List", "<", "Object", ">", "contextSpecificObjects", "=", "new", "ArrayList", "<", "Object", ">", "(", ")", ";", "techTreeState", "=", "getTechTree", "(", ")", ".", "getTechSet", "(", ")", ";", ...
Use the save method to launch a scan
[ "Use", "the", "save", "method", "to", "launch", "a", "scan" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/ascan/CustomScanDialog.java#L716-L801
129,405
zaproxy/zaproxy
src/org/zaproxy/zap/extension/ascan/CustomScanDialog.java
CustomScanDialog.enableUserDefinedRPC
public void enableUserDefinedRPC() { int enabledRpc = scannerParam.getTargetParamsEnabledRPC(); enabledRpc |= ScannerParam.RPC_USERDEF; scannerParam.setTargetParamsEnabledRPC(enabledRpc); }
java
public void enableUserDefinedRPC() { int enabledRpc = scannerParam.getTargetParamsEnabledRPC(); enabledRpc |= ScannerParam.RPC_USERDEF; scannerParam.setTargetParamsEnabledRPC(enabledRpc); }
[ "public", "void", "enableUserDefinedRPC", "(", ")", "{", "int", "enabledRpc", "=", "scannerParam", ".", "getTargetParamsEnabledRPC", "(", ")", ";", "enabledRpc", "|=", "ScannerParam", ".", "RPC_USERDEF", ";", "scannerParam", ".", "setTargetParamsEnabledRPC", "(", "e...
Force UserDefinedRPC setting
[ "Force", "UserDefinedRPC", "setting" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/ascan/CustomScanDialog.java#L867-L871
129,406
zaproxy/zaproxy
src/org/zaproxy/zap/extension/users/DialogAddUser.java
DialogAddUser.initializeCredentialsConfigPanel
protected void initializeCredentialsConfigPanel() { // Initialize the credentials config panel AuthenticationMethodType type = workingContext.getAuthenticationMethod().getType(); if (type.hasCredentialsOptionsPanel()) { credentialsPanel = type.buildCredentialsOptionsPanel(configuredCredentials, workingContext)...
java
protected void initializeCredentialsConfigPanel() { // Initialize the credentials config panel AuthenticationMethodType type = workingContext.getAuthenticationMethod().getType(); if (type.hasCredentialsOptionsPanel()) { credentialsPanel = type.buildCredentialsOptionsPanel(configuredCredentials, workingContext)...
[ "protected", "void", "initializeCredentialsConfigPanel", "(", ")", "{", "// Initialize the credentials config panel", "AuthenticationMethodType", "type", "=", "workingContext", ".", "getAuthenticationMethod", "(", ")", ".", "getType", "(", ")", ";", "if", "(", "type", "...
Initialize credentials config panel.
[ "Initialize", "credentials", "config", "panel", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/users/DialogAddUser.java#L113-L122
129,407
zaproxy/zaproxy
src/org/parosproxy/paros/view/MainFooterPanel.java
MainFooterPanel.getToolbarLeft
private JToolBar getToolbarLeft() { if (footerToolbarLeft == null) { footerToolbarLeft = new JToolBar(); footerToolbarLeft.setEnabled(true); footerToolbarLeft.setFloatable(false); footerToolbarLeft.setRollover(true); footerToolbarLeft.setName("Footer Toolbar Left"); footerToolbarLeft.setBorder(Borde...
java
private JToolBar getToolbarLeft() { if (footerToolbarLeft == null) { footerToolbarLeft = new JToolBar(); footerToolbarLeft.setEnabled(true); footerToolbarLeft.setFloatable(false); footerToolbarLeft.setRollover(true); footerToolbarLeft.setName("Footer Toolbar Left"); footerToolbarLeft.setBorder(Borde...
[ "private", "JToolBar", "getToolbarLeft", "(", ")", "{", "if", "(", "footerToolbarLeft", "==", "null", ")", "{", "footerToolbarLeft", "=", "new", "JToolBar", "(", ")", ";", "footerToolbarLeft", ".", "setEnabled", "(", "true", ")", ";", "footerToolbarLeft", ".",...
Left toolbar for alerts
[ "Left", "toolbar", "for", "alerts" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/view/MainFooterPanel.java#L123-L133
129,408
zaproxy/zaproxy
src/org/parosproxy/paros/view/MainFooterPanel.java
MainFooterPanel.getToolbarRight
private JToolBar getToolbarRight() { if (footerToolbarRight == null) { footerToolbarRight = new JToolBar(); footerToolbarRight.setEnabled(true); footerToolbarRight.setFloatable(false); footerToolbarRight.setRollover(true); footerToolbarRight.setName("Footer Toolbar Right"); footerToolbarRight.setBor...
java
private JToolBar getToolbarRight() { if (footerToolbarRight == null) { footerToolbarRight = new JToolBar(); footerToolbarRight.setEnabled(true); footerToolbarRight.setFloatable(false); footerToolbarRight.setRollover(true); footerToolbarRight.setName("Footer Toolbar Right"); footerToolbarRight.setBor...
[ "private", "JToolBar", "getToolbarRight", "(", ")", "{", "if", "(", "footerToolbarRight", "==", "null", ")", "{", "footerToolbarRight", "=", "new", "JToolBar", "(", ")", ";", "footerToolbarRight", ".", "setEnabled", "(", "true", ")", ";", "footerToolbarRight", ...
Right toolbar for current scan results
[ "Right", "toolbar", "for", "current", "scan", "results" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/view/MainFooterPanel.java#L136-L146
129,409
zaproxy/zaproxy
src/org/parosproxy/paros/view/MainFooterPanel.java
MainFooterPanel.addFooterToolbarRightLabel
public void addFooterToolbarRightLabel (JLabel label) { DisplayUtils.scaleIcon(label); this.footerToolbarRight.add(label); this.validate(); }
java
public void addFooterToolbarRightLabel (JLabel label) { DisplayUtils.scaleIcon(label); this.footerToolbarRight.add(label); this.validate(); }
[ "public", "void", "addFooterToolbarRightLabel", "(", "JLabel", "label", ")", "{", "DisplayUtils", ".", "scaleIcon", "(", "label", ")", ";", "this", ".", "footerToolbarRight", ".", "add", "(", "label", ")", ";", "this", ".", "validate", "(", ")", ";", "}" ]
Support for dynamic scanning results in the footer
[ "Support", "for", "dynamic", "scanning", "results", "in", "the", "footer" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/view/MainFooterPanel.java#L230-L234
129,410
zaproxy/zaproxy
src/org/zaproxy/zap/extension/users/ExtensionUserManagement.java
ExtensionUserManagement.getExtensionHttpSessions
protected ExtensionHttpSessions getExtensionHttpSessions() { if (extensionHttpSessions == null) { extensionHttpSessions = Control.getSingleton().getExtensionLoader().getExtension(ExtensionHttpSessions.class); if (extensionHttpSessions == null) log.error("Http Sessions Extension should be enabled for the " ...
java
protected ExtensionHttpSessions getExtensionHttpSessions() { if (extensionHttpSessions == null) { extensionHttpSessions = Control.getSingleton().getExtensionLoader().getExtension(ExtensionHttpSessions.class); if (extensionHttpSessions == null) log.error("Http Sessions Extension should be enabled for the " ...
[ "protected", "ExtensionHttpSessions", "getExtensionHttpSessions", "(", ")", "{", "if", "(", "extensionHttpSessions", "==", "null", ")", "{", "extensionHttpSessions", "=", "Control", ".", "getSingleton", "(", ")", ".", "getExtensionLoader", "(", ")", ".", "getExtensi...
Gets the ExtensionHttpSessions, if it's enabled. @return the Http Sessions extension or null, if it's not available
[ "Gets", "the", "ExtensionHttpSessions", "if", "it", "s", "enabled", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/users/ExtensionUserManagement.java#L112-L121
129,411
zaproxy/zaproxy
src/org/zaproxy/zap/extension/users/ExtensionUserManagement.java
ExtensionUserManagement.getContextPanel
private ContextUsersPanel getContextPanel(int contextId) { ContextUsersPanel panel = this.userPanelsMap.get(contextId); if (panel == null) { panel = new ContextUsersPanel(this, contextId); this.userPanelsMap.put(contextId, panel); } return panel; }
java
private ContextUsersPanel getContextPanel(int contextId) { ContextUsersPanel panel = this.userPanelsMap.get(contextId); if (panel == null) { panel = new ContextUsersPanel(this, contextId); this.userPanelsMap.put(contextId, panel); } return panel; }
[ "private", "ContextUsersPanel", "getContextPanel", "(", "int", "contextId", ")", "{", "ContextUsersPanel", "panel", "=", "this", ".", "userPanelsMap", ".", "get", "(", "contextId", ")", ";", "if", "(", "panel", "==", "null", ")", "{", "panel", "=", "new", ...
Gets the context panel for a given context. @param contextId the context id @return the context panel
[ "Gets", "the", "context", "panel", "for", "a", "given", "context", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/users/ExtensionUserManagement.java#L184-L191
129,412
zaproxy/zaproxy
src/org/zaproxy/zap/extension/users/ExtensionUserManagement.java
ExtensionUserManagement.getContextUserAuthManager
public ContextUserAuthManager getContextUserAuthManager(int contextId) { ContextUserAuthManager manager = contextManagers.get(contextId); if (manager == null) { manager = new ContextUserAuthManager(contextId); contextManagers.put(contextId, manager); } return manager; }
java
public ContextUserAuthManager getContextUserAuthManager(int contextId) { ContextUserAuthManager manager = contextManagers.get(contextId); if (manager == null) { manager = new ContextUserAuthManager(contextId); contextManagers.put(contextId, manager); } return manager; }
[ "public", "ContextUserAuthManager", "getContextUserAuthManager", "(", "int", "contextId", ")", "{", "ContextUserAuthManager", "manager", "=", "contextManagers", ".", "get", "(", "contextId", ")", ";", "if", "(", "manager", "==", "null", ")", "{", "manager", "=", ...
Gets the context user auth manager for a given context. @param contextId the context id @return the context user auth manager
[ "Gets", "the", "context", "user", "auth", "manager", "for", "a", "given", "context", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/users/ExtensionUserManagement.java#L199-L206
129,413
zaproxy/zaproxy
src/org/zaproxy/zap/extension/users/ExtensionUserManagement.java
ExtensionUserManagement.getUIConfiguredUsers
public List<User> getUIConfiguredUsers(int contextId) { ContextUsersPanel panel = this.userPanelsMap.get(contextId); if (panel != null) { return Collections.unmodifiableList(panel.getUsersTableModel().getUsers()); } return null; }
java
public List<User> getUIConfiguredUsers(int contextId) { ContextUsersPanel panel = this.userPanelsMap.get(contextId); if (panel != null) { return Collections.unmodifiableList(panel.getUsersTableModel().getUsers()); } return null; }
[ "public", "List", "<", "User", ">", "getUIConfiguredUsers", "(", "int", "contextId", ")", "{", "ContextUsersPanel", "panel", "=", "this", ".", "userPanelsMap", ".", "get", "(", "contextId", ")", ";", "if", "(", "panel", "!=", "null", ")", "{", "return", ...
Gets an unmodifiable view of the users that are currently shown in the UI. @param contextId the context id @return the uI configured users
[ "Gets", "an", "unmodifiable", "view", "of", "the", "users", "that", "are", "currently", "shown", "in", "the", "UI", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/users/ExtensionUserManagement.java#L214-L220
129,414
zaproxy/zaproxy
src/org/zaproxy/zap/extension/users/ExtensionUserManagement.java
ExtensionUserManagement.getUIConfiguredUsersModel
public UsersTableModel getUIConfiguredUsersModel(int contextId) { ContextUsersPanel panel = this.userPanelsMap.get(contextId); if (panel != null) { return panel.getUsersTableModel(); } return null; }
java
public UsersTableModel getUIConfiguredUsersModel(int contextId) { ContextUsersPanel panel = this.userPanelsMap.get(contextId); if (panel != null) { return panel.getUsersTableModel(); } return null; }
[ "public", "UsersTableModel", "getUIConfiguredUsersModel", "(", "int", "contextId", ")", "{", "ContextUsersPanel", "panel", "=", "this", ".", "userPanelsMap", ".", "get", "(", "contextId", ")", ";", "if", "(", "panel", "!=", "null", ")", "{", "return", "panel",...
Gets the model of the users that are currently shown in the UI. @param contextId the context id @return the users model, if any, or null, if there is no panel for the given model
[ "Gets", "the", "model", "of", "the", "users", "that", "are", "currently", "shown", "in", "the", "UI", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/users/ExtensionUserManagement.java#L228-L234
129,415
zaproxy/zaproxy
src/org/parosproxy/paros/view/FindDialog.java
FindDialog.getDialog
public static FindDialog getDialog(Window parent, boolean modal) { if (parent == null) { throw new IllegalArgumentException("The parent must not be null."); } FindDialog activeDialog = getParentsMap().get(parent); if (activeDialog != null) { activeDialog.getTxtFind().requestFocus(); return act...
java
public static FindDialog getDialog(Window parent, boolean modal) { if (parent == null) { throw new IllegalArgumentException("The parent must not be null."); } FindDialog activeDialog = getParentsMap().get(parent); if (activeDialog != null) { activeDialog.getTxtFind().requestFocus(); return act...
[ "public", "static", "FindDialog", "getDialog", "(", "Window", "parent", ",", "boolean", "modal", ")", "{", "if", "(", "parent", "==", "null", ")", "{", "throw", "new", "IllegalArgumentException", "(", "\"The parent must not be null.\"", ")", ";", "}", "FindDialo...
Get the FindDialog for the parent if there is one or creates and returns a new one. @param parent the parent Window (or Frame) for this FindDialog @param modal a boolean indicating whether the FindDialog should ({@code true}), or shouldn't ({@code false}) be modal. @return The existing FindDialog for the parent (if th...
[ "Get", "the", "FindDialog", "for", "the", "parent", "if", "there", "is", "one", "or", "creates", "and", "returns", "a", "new", "one", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/view/FindDialog.java#L148-L167
129,416
zaproxy/zaproxy
src/org/parosproxy/paros/view/FindDialog.java
FindDialog.getBtnFind
private JButton getBtnFind() { if (btnFind == null) { btnFind = new JButton(); btnFind.setText(Constant.messages.getString("edit.find.button.find")); btnFind.addActionListener(new java.awt.event.ActionListener() { @Override public void actionPerformed(java.awt.event.ActionEvent e) { ...
java
private JButton getBtnFind() { if (btnFind == null) { btnFind = new JButton(); btnFind.setText(Constant.messages.getString("edit.find.button.find")); btnFind.addActionListener(new java.awt.event.ActionListener() { @Override public void actionPerformed(java.awt.event.ActionEvent e) { ...
[ "private", "JButton", "getBtnFind", "(", ")", "{", "if", "(", "btnFind", "==", "null", ")", "{", "btnFind", "=", "new", "JButton", "(", ")", ";", "btnFind", ".", "setText", "(", "Constant", ".", "messages", ".", "getString", "(", "\"edit.find.button.find\"...
This method initializes btnFind @return javax.swing.JButton
[ "This", "method", "initializes", "btnFind" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/view/FindDialog.java#L255-L271
129,417
zaproxy/zaproxy
src/org/zaproxy/zap/extension/httppanel/view/syntaxhighlight/HttpPanelSyntaxHighlightTextArea.java
HttpPanelSyntaxHighlightTextArea.highlightAll
private void highlightAll() { HighlighterManager highlighter = HighlighterManager.getInstance(); LinkedList<HighlightSearchEntry> highlights = highlighter.getHighlights(); for (HighlightSearchEntry entry: highlights) { highlightEntryParser(entry); } }
java
private void highlightAll() { HighlighterManager highlighter = HighlighterManager.getInstance(); LinkedList<HighlightSearchEntry> highlights = highlighter.getHighlights(); for (HighlightSearchEntry entry: highlights) { highlightEntryParser(entry); } }
[ "private", "void", "highlightAll", "(", ")", "{", "HighlighterManager", "highlighter", "=", "HighlighterManager", ".", "getInstance", "(", ")", ";", "LinkedList", "<", "HighlightSearchEntry", ">", "highlights", "=", "highlighter", ".", "getHighlights", "(", ")", "...
Highlight all search strings from HighlightManager
[ "Highlight", "all", "search", "strings", "from", "HighlightManager" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/httppanel/view/syntaxhighlight/HttpPanelSyntaxHighlightTextArea.java#L184-L191
129,418
zaproxy/zaproxy
src/org/zaproxy/zap/extension/httppanel/view/syntaxhighlight/HttpPanelSyntaxHighlightTextArea.java
HttpPanelSyntaxHighlightTextArea.highlightEntryParser
private void highlightEntryParser(HighlightSearchEntry entry) { String text; int lastPos = 0; text = this.getText(); Highlighter hilite = this.getHighlighter(); HighlightPainter painter = new DefaultHighlighter.DefaultHighlightPainter(entry.getColor()); while ( (lastPos = text.indexOf(entr...
java
private void highlightEntryParser(HighlightSearchEntry entry) { String text; int lastPos = 0; text = this.getText(); Highlighter hilite = this.getHighlighter(); HighlightPainter painter = new DefaultHighlighter.DefaultHighlightPainter(entry.getColor()); while ( (lastPos = text.indexOf(entr...
[ "private", "void", "highlightEntryParser", "(", "HighlightSearchEntry", "entry", ")", "{", "String", "text", ";", "int", "lastPos", "=", "0", ";", "text", "=", "this", ".", "getText", "(", ")", ";", "Highlighter", "hilite", "=", "this", ".", "getHighlighter"...
Highlight all found strings
[ "Highlight", "all", "found", "strings" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/httppanel/view/syntaxhighlight/HttpPanelSyntaxHighlightTextArea.java#L195-L212
129,419
zaproxy/zaproxy
src/org/zaproxy/zap/view/widgets/UsersListModel.java
UsersListModel.setSelectedInternalItem
public void setSelectedInternalItem(User user) { User internalUser = null; int index = getIndexOf(user); if (index != -1) { internalUser = getElementAt(index); } else if (getSize() > 0) { internalUser = getElementAt(0); } setSelectedItemImpl(internalUser); }
java
public void setSelectedInternalItem(User user) { User internalUser = null; int index = getIndexOf(user); if (index != -1) { internalUser = getElementAt(index); } else if (getSize() > 0) { internalUser = getElementAt(0); } setSelectedItemImpl(internalUser); }
[ "public", "void", "setSelectedInternalItem", "(", "User", "user", ")", "{", "User", "internalUser", "=", "null", ";", "int", "index", "=", "getIndexOf", "(", "user", ")", ";", "if", "(", "index", "!=", "-", "1", ")", "{", "internalUser", "=", "getElement...
Sets the selected item as the actual internal item with the same id as the provided user. @param user the new selected internal item
[ "Sets", "the", "selected", "item", "as", "the", "actual", "internal", "item", "with", "the", "same", "id", "as", "the", "provided", "user", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/view/widgets/UsersListModel.java#L117-L127
129,420
zaproxy/zaproxy
src/org/zaproxy/zap/view/widgets/UsersListModel.java
UsersListModel.getIndexOf
public int getIndexOf(Object object) { int index = tableModel.getUsers().indexOf(object); if (index < 0 && customUsers != null) return tableModel.getUsers().size() + ArrayUtils.indexOf(customUsers, object); return index; }
java
public int getIndexOf(Object object) { int index = tableModel.getUsers().indexOf(object); if (index < 0 && customUsers != null) return tableModel.getUsers().size() + ArrayUtils.indexOf(customUsers, object); return index; }
[ "public", "int", "getIndexOf", "(", "Object", "object", ")", "{", "int", "index", "=", "tableModel", ".", "getUsers", "(", ")", ".", "indexOf", "(", "object", ")", ";", "if", "(", "index", "<", "0", "&&", "customUsers", "!=", "null", ")", "return", "...
Returns the index of the specified element in the model's item list. @param object the element. @return The index of the specified element in the model's item list, or -1 if it wasn't found
[ "Returns", "the", "index", "of", "the", "specified", "element", "in", "the", "model", "s", "item", "list", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/view/widgets/UsersListModel.java#L136-L141
129,421
zaproxy/zaproxy
src/org/parosproxy/paros/core/scanner/VariantCustom.java
VariantCustom.setMessage
@Override public void setMessage(HttpMessage msg) { try { if (script != null) { script.parseParameters(this, msg); } } catch (Exception e) { // Catch Exception instead of ScriptException because script engine implementations might ...
java
@Override public void setMessage(HttpMessage msg) { try { if (script != null) { script.parseParameters(this, msg); } } catch (Exception e) { // Catch Exception instead of ScriptException because script engine implementations might ...
[ "@", "Override", "public", "void", "setMessage", "(", "HttpMessage", "msg", ")", "{", "try", "{", "if", "(", "script", "!=", "null", ")", "{", "script", ".", "parseParameters", "(", "this", ",", "msg", ")", ";", "}", "}", "catch", "(", "Exception", "...
Set the current message that this Variant has to scan @param msg the message object (remember Response is not set)
[ "Set", "the", "current", "message", "that", "this", "Variant", "has", "to", "scan" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/core/scanner/VariantCustom.java#L77-L89
129,422
zaproxy/zaproxy
src/org/parosproxy/paros/core/scanner/VariantCustom.java
VariantCustom.getParamName
public String getParamName(int index) { return (index < params.size()) ? params.get(index).getName() : null; }
java
public String getParamName(int index) { return (index < params.size()) ? params.get(index).getName() : null; }
[ "public", "String", "getParamName", "(", "int", "index", ")", "{", "return", "(", "index", "<", "params", ".", "size", "(", ")", ")", "?", "params", ".", "get", "(", "index", ")", ".", "getName", "(", ")", ":", "null", ";", "}" ]
Support method to get back the name of the n-th parameter @param index the index of the requested parameter @return the parameter name if exists
[ "Support", "method", "to", "get", "back", "the", "name", "of", "the", "n", "-", "th", "parameter" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/core/scanner/VariantCustom.java#L105-L107
129,423
zaproxy/zaproxy
src/org/parosproxy/paros/core/scanner/VariantCustom.java
VariantCustom.getParamValue
public String getParamValue(int index) { return (index < params.size()) ? params.get(index).getValue() : null; }
java
public String getParamValue(int index) { return (index < params.size()) ? params.get(index).getValue() : null; }
[ "public", "String", "getParamValue", "(", "int", "index", ")", "{", "return", "(", "index", "<", "params", ".", "size", "(", ")", ")", "?", "params", ".", "get", "(", "index", ")", ".", "getValue", "(", ")", ":", "null", ";", "}" ]
Support method to get back the value of the n-th parameter @param index the index of the requested parameter @return the parameter value if exists
[ "Support", "method", "to", "get", "back", "the", "value", "of", "the", "n", "-", "th", "parameter" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/core/scanner/VariantCustom.java#L114-L116
129,424
zaproxy/zaproxy
src/org/parosproxy/paros/core/scanner/VariantCustom.java
VariantCustom.addParam
public void addParam(String name, String value, int type) { // Current size usually is equal to the position params.add(new NameValuePair(type, name, value, params.size())); }
java
public void addParam(String name, String value, int type) { // Current size usually is equal to the position params.add(new NameValuePair(type, name, value, params.size())); }
[ "public", "void", "addParam", "(", "String", "name", ",", "String", "value", ",", "int", "type", ")", "{", "// Current size usually is equal to the position\r", "params", ".", "add", "(", "new", "NameValuePair", "(", "type", ",", "name", ",", "value", ",", "pa...
Support method to add a new param to this custom variant @param name the param name @param value the value of this parameter @param type the type of this parameter
[ "Support", "method", "to", "add", "a", "new", "param", "to", "this", "custom", "variant" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/core/scanner/VariantCustom.java#L142-L145
129,425
zaproxy/zaproxy
src/org/parosproxy/paros/core/scanner/VariantCustom.java
VariantCustom.addParamQuery
public void addParamQuery(String name, String value) { addParam(name, value, NameValuePair.TYPE_QUERY_STRING); }
java
public void addParamQuery(String name, String value) { addParam(name, value, NameValuePair.TYPE_QUERY_STRING); }
[ "public", "void", "addParamQuery", "(", "String", "name", ",", "String", "value", ")", "{", "addParam", "(", "name", ",", "value", ",", "NameValuePair", ".", "TYPE_QUERY_STRING", ")", ";", "}" ]
Support method to add a new QueryString param to this custom variant @param name the param name @param value the value of this parameter
[ "Support", "method", "to", "add", "a", "new", "QueryString", "param", "to", "this", "custom", "variant" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/core/scanner/VariantCustom.java#L152-L154
129,426
zaproxy/zaproxy
src/org/parosproxy/paros/core/scanner/VariantCustom.java
VariantCustom.addParamPost
public void addParamPost(String name, String value) { addParam(name, value, NameValuePair.TYPE_POST_DATA); }
java
public void addParamPost(String name, String value) { addParam(name, value, NameValuePair.TYPE_POST_DATA); }
[ "public", "void", "addParamPost", "(", "String", "name", ",", "String", "value", ")", "{", "addParam", "(", "name", ",", "value", ",", "NameValuePair", ".", "TYPE_POST_DATA", ")", ";", "}" ]
Support method to add a new PostData param to this custom variant @param name the param name @param value the value of this parameter
[ "Support", "method", "to", "add", "a", "new", "PostData", "param", "to", "this", "custom", "variant" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/core/scanner/VariantCustom.java#L161-L163
129,427
zaproxy/zaproxy
src/org/parosproxy/paros/core/scanner/VariantCustom.java
VariantCustom.addParamHeader
public void addParamHeader(String name, String value) { addParam(name, value, NameValuePair.TYPE_HEADER); }
java
public void addParamHeader(String name, String value) { addParam(name, value, NameValuePair.TYPE_HEADER); }
[ "public", "void", "addParamHeader", "(", "String", "name", ",", "String", "value", ")", "{", "addParam", "(", "name", ",", "value", ",", "NameValuePair", ".", "TYPE_HEADER", ")", ";", "}" ]
Support method to add a new Header param to this custom variant @param name the param name @param value the value of this parameter
[ "Support", "method", "to", "add", "a", "new", "Header", "param", "to", "this", "custom", "variant" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/core/scanner/VariantCustom.java#L170-L172
129,428
zaproxy/zaproxy
src/org/parosproxy/paros/core/scanner/VariantCustom.java
VariantCustom.setParameter
private String setParameter(HttpMessage msg, NameValuePair originalPair, String paramName, String value, boolean escaped) { try { if (script != null) { currentParam = originalPair; script.setParameter(this, msg, paramName, value, escaped); } ...
java
private String setParameter(HttpMessage msg, NameValuePair originalPair, String paramName, String value, boolean escaped) { try { if (script != null) { currentParam = originalPair; script.setParameter(this, msg, paramName, value, escaped); } ...
[ "private", "String", "setParameter", "(", "HttpMessage", "msg", ",", "NameValuePair", "originalPair", ",", "String", "paramName", ",", "String", "value", ",", "boolean", "escaped", ")", "{", "try", "{", "if", "(", "script", "!=", "null", ")", "{", "currentPa...
Inner method for correct scripting @param msg the message that need to be modified @param originalPair the original {@code NameValuePair} being tested. @param paramName the name of the parameter @param value the value thta should be set for this parameter @param escaped true if the parameter has been already escaped @r...
[ "Inner", "method", "for", "correct", "scripting" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/core/scanner/VariantCustom.java#L220-L236
129,429
zaproxy/zaproxy
src/org/parosproxy/paros/view/LicenseFrame.java
LicenseFrame.getBtnAccept
private JButton getBtnAccept() { if (btnAccept == null) { btnAccept = new JButton(); btnAccept.setText("Accept"); btnAccept.addActionListener(new java.awt.event.ActionListener() { @Override public void actionPerformed(java.awt.event.ActionEvent e) { accepted = true; Licen...
java
private JButton getBtnAccept() { if (btnAccept == null) { btnAccept = new JButton(); btnAccept.setText("Accept"); btnAccept.addActionListener(new java.awt.event.ActionListener() { @Override public void actionPerformed(java.awt.event.ActionEvent e) { accepted = true; Licen...
[ "private", "JButton", "getBtnAccept", "(", ")", "{", "if", "(", "btnAccept", "==", "null", ")", "{", "btnAccept", "=", "new", "JButton", "(", ")", ";", "btnAccept", ".", "setText", "(", "\"Accept\"", ")", ";", "btnAccept", ".", "addActionListener", "(", ...
This method initializes btnAccept @return javax.swing.JButton
[ "This", "method", "initializes", "btnAccept" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/view/LicenseFrame.java#L149-L165
129,430
zaproxy/zaproxy
src/org/parosproxy/paros/view/LicenseFrame.java
LicenseFrame.getBtnDecline
private JButton getBtnDecline() { if (btnDecline == null) { btnDecline = new JButton(); btnDecline.setText("Decline"); btnDecline.addActionListener(new java.awt.event.ActionListener() { @Override public void actionPerformed(java.awt.event.ActionEvent e) { accepted = false; S...
java
private JButton getBtnDecline() { if (btnDecline == null) { btnDecline = new JButton(); btnDecline.setText("Decline"); btnDecline.addActionListener(new java.awt.event.ActionListener() { @Override public void actionPerformed(java.awt.event.ActionEvent e) { accepted = false; S...
[ "private", "JButton", "getBtnDecline", "(", ")", "{", "if", "(", "btnDecline", "==", "null", ")", "{", "btnDecline", "=", "new", "JButton", "(", ")", ";", "btnDecline", ".", "setText", "(", "\"Decline\"", ")", ";", "btnDecline", ".", "addActionListener", "...
This method initializes btnDecline @return javax.swing.JButton
[ "This", "method", "initializes", "btnDecline" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/view/LicenseFrame.java#L171-L187
129,431
zaproxy/zaproxy
src/org/zaproxy/zap/Version.java
Version.matches
public boolean matches(String versionRange) throws IllegalArgumentException { Validate.notEmpty(versionRange, "Parameter versionRange must not be null nor empty."); try { return impl.satisfies(versionRange); } catch (com.github.zafarkhaja.semver.ParseException e) { throw...
java
public boolean matches(String versionRange) throws IllegalArgumentException { Validate.notEmpty(versionRange, "Parameter versionRange must not be null nor empty."); try { return impl.satisfies(versionRange); } catch (com.github.zafarkhaja.semver.ParseException e) { throw...
[ "public", "boolean", "matches", "(", "String", "versionRange", ")", "throws", "IllegalArgumentException", "{", "Validate", ".", "notEmpty", "(", "versionRange", ",", "\"Parameter versionRange must not be null nor empty.\"", ")", ";", "try", "{", "return", "impl", ".", ...
Tells whether or not the given version range matches this version. @param versionRange the range version @return {@code true} if this version matches the given version range, {@code false} otherwise @throws IllegalArgumentException if {@code versionRange} is null or empty, or not valid range version @see #isValidVersi...
[ "Tells", "whether", "or", "not", "the", "given", "version", "range", "matches", "this", "version", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/Version.java#L91-L99
129,432
zaproxy/zaproxy
src/org/zaproxy/zap/Version.java
Version.isValidVersionRange
public static boolean isValidVersionRange(String versionRange) { try { ExpressionParser.newInstance().parse(versionRange); return true; } catch (com.github.zafarkhaja.semver.ParseException ignore) { // Ignore. } return false; }
java
public static boolean isValidVersionRange(String versionRange) { try { ExpressionParser.newInstance().parse(versionRange); return true; } catch (com.github.zafarkhaja.semver.ParseException ignore) { // Ignore. } return false; }
[ "public", "static", "boolean", "isValidVersionRange", "(", "String", "versionRange", ")", "{", "try", "{", "ExpressionParser", ".", "newInstance", "(", ")", ".", "parse", "(", "versionRange", ")", ";", "return", "true", ";", "}", "catch", "(", "com", ".", ...
Tells whether or not the given version range is valid. @param versionRange the version range to test. @return {@code true} if the version range is valid, {@code false} otherwise. @since 2.7.0 @see #matches(String)
[ "Tells", "whether", "or", "not", "the", "given", "version", "range", "is", "valid", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/Version.java#L109-L117
129,433
zaproxy/zaproxy
src/org/zaproxy/zap/utils/I18N.java
I18N.getChar
public char getChar(String key) { try { String str = this.getStringImpl(key); if (str.length() > 0) { return str.charAt(0); } } catch (Exception e) { // Not defined } return '\u0000'; }
java
public char getChar(String key) { try { String str = this.getStringImpl(key); if (str.length() > 0) { return str.charAt(0); } } catch (Exception e) { // Not defined } return '\u0000'; }
[ "public", "char", "getChar", "(", "String", "key", ")", "{", "try", "{", "String", "str", "=", "this", ".", "getStringImpl", "(", "key", ")", ";", "if", "(", "str", ".", "length", "(", ")", ">", "0", ")", "{", "return", "str", ".", "charAt", "(",...
Returns the specified char from the language file. As these are typically used for mnemonics the 'null' char is returned if the key is not defined @param key the key of the char @return the char read, or null char if not found
[ "Returns", "the", "specified", "char", "from", "the", "language", "file", ".", "As", "these", "are", "typically", "used", "for", "mnemonics", "the", "null", "char", "is", "returned", "if", "the", "key", "is", "not", "defined" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/utils/I18N.java#L172-L182
129,434
zaproxy/zaproxy
src/org/zaproxy/zap/utils/ApiUtils.java
ApiUtils.getIntParam
public static int getIntParam(JSONObject params, String paramName) throws ApiException { if (!params.containsKey(paramName)) { throw new ApiException(ApiException.Type.MISSING_PARAMETER, paramName); } try { return params.getInt(paramName); } catch (JSONException e) { throw new ApiException(ApiExceptio...
java
public static int getIntParam(JSONObject params, String paramName) throws ApiException { if (!params.containsKey(paramName)) { throw new ApiException(ApiException.Type.MISSING_PARAMETER, paramName); } try { return params.getInt(paramName); } catch (JSONException e) { throw new ApiException(ApiExceptio...
[ "public", "static", "int", "getIntParam", "(", "JSONObject", "params", ",", "String", "paramName", ")", "throws", "ApiException", "{", "if", "(", "!", "params", ".", "containsKey", "(", "paramName", ")", ")", "{", "throw", "new", "ApiException", "(", "ApiExc...
Gets the int param with a given name and throws an exception accordingly if not found or valid. @param params the params @param paramName the param name @return the int param @throws ApiException the api exception
[ "Gets", "the", "int", "param", "with", "a", "given", "name", "and", "throws", "an", "exception", "accordingly", "if", "not", "found", "or", "valid", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/utils/ApiUtils.java#L46-L56
129,435
zaproxy/zaproxy
src/org/zaproxy/zap/utils/ApiUtils.java
ApiUtils.getBooleanParam
public static boolean getBooleanParam(JSONObject params, String paramName) throws ApiException { if (!params.containsKey(paramName)) { throw new ApiException(ApiException.Type.MISSING_PARAMETER, paramName); } try { return params.getBoolean(paramName); } catch (JSONException e) { throw new ApiException...
java
public static boolean getBooleanParam(JSONObject params, String paramName) throws ApiException { if (!params.containsKey(paramName)) { throw new ApiException(ApiException.Type.MISSING_PARAMETER, paramName); } try { return params.getBoolean(paramName); } catch (JSONException e) { throw new ApiException...
[ "public", "static", "boolean", "getBooleanParam", "(", "JSONObject", "params", ",", "String", "paramName", ")", "throws", "ApiException", "{", "if", "(", "!", "params", ".", "containsKey", "(", "paramName", ")", ")", "{", "throw", "new", "ApiException", "(", ...
Gets a boolean from the parameter with the given name. @param params the API parameters @param paramName the name of the parameter @return the boolean value @throws ApiException if the parameter is missing ({@link org.zaproxy.zap.extension.api.ApiException.Type#MISSING_PARAMETER MISSING_PARAMETER}) or not a boolean ({...
[ "Gets", "a", "boolean", "from", "the", "parameter", "with", "the", "given", "name", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/utils/ApiUtils.java#L69-L79
129,436
zaproxy/zaproxy
src/org/zaproxy/zap/utils/ApiUtils.java
ApiUtils.getOptionalStringParam
public static String getOptionalStringParam(JSONObject params, String paramName) { if (params.containsKey(paramName)) { return params.getString(paramName); } return null; }
java
public static String getOptionalStringParam(JSONObject params, String paramName) { if (params.containsKey(paramName)) { return params.getString(paramName); } return null; }
[ "public", "static", "String", "getOptionalStringParam", "(", "JSONObject", "params", ",", "String", "paramName", ")", "{", "if", "(", "params", ".", "containsKey", "(", "paramName", ")", ")", "{", "return", "params", ".", "getString", "(", "paramName", ")", ...
Gets an optional string param, returning null if the parameter was not found. @param params the params @param paramName the param name @return the optional string param
[ "Gets", "an", "optional", "string", "param", "returning", "null", "if", "the", "parameter", "was", "not", "found", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/utils/ApiUtils.java#L88-L93
129,437
zaproxy/zaproxy
src/org/zaproxy/zap/utils/ApiUtils.java
ApiUtils.getNonEmptyStringParam
public static String getNonEmptyStringParam(JSONObject params, String paramName) throws ApiException { if (!params.containsKey(paramName)) { throw new ApiException(Type.MISSING_PARAMETER, paramName); } String value = params.getString(paramName); if (value == null || value.isEmpty()) { throw new ApiExcepti...
java
public static String getNonEmptyStringParam(JSONObject params, String paramName) throws ApiException { if (!params.containsKey(paramName)) { throw new ApiException(Type.MISSING_PARAMETER, paramName); } String value = params.getString(paramName); if (value == null || value.isEmpty()) { throw new ApiExcepti...
[ "public", "static", "String", "getNonEmptyStringParam", "(", "JSONObject", "params", ",", "String", "paramName", ")", "throws", "ApiException", "{", "if", "(", "!", "params", ".", "containsKey", "(", "paramName", ")", ")", "{", "throw", "new", "ApiException", ...
Gets the non empty string param with a given name and throws an exception accordingly if not found or empty. @param params the params @param paramName the param name @return the non empty string param @throws ApiException the api exception thown if param not found or string empty
[ "Gets", "the", "non", "empty", "string", "param", "with", "a", "given", "name", "and", "throws", "an", "exception", "accordingly", "if", "not", "found", "or", "empty", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/utils/ApiUtils.java#L104-L113
129,438
zaproxy/zaproxy
src/org/parosproxy/paros/extension/history/PopupMenuResendSites.java
PopupMenuResendSites.initialize
private void initialize() { this.setText(Constant.messages.getString("sites.resend.popup")); this.addActionListener(new java.awt.event.ActionListener() { @Override public void actionPerformed(java.awt.event.ActionEvent evt) { if (treeSite != null) { ...
java
private void initialize() { this.setText(Constant.messages.getString("sites.resend.popup")); this.addActionListener(new java.awt.event.ActionListener() { @Override public void actionPerformed(java.awt.event.ActionEvent evt) { if (treeSite != null) { ...
[ "private", "void", "initialize", "(", ")", "{", "this", ".", "setText", "(", "Constant", ".", "messages", ".", "getString", "(", "\"sites.resend.popup\"", ")", ")", ";", "this", ".", "addActionListener", "(", "new", "java", ".", "awt", ".", "event", ".", ...
This method initialises this
[ "This", "method", "initialises", "this" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/extension/history/PopupMenuResendSites.java#L70-L96
129,439
zaproxy/zaproxy
src/org/zaproxy/zap/extension/history/HistoryFilterPlusDialog.java
HistoryFilterPlusDialog.getBtnApply
private JButton getBtnApply() { if (btnApply == null) { btnApply = new JButton(); btnApply.setText(Constant.messages.getString("history.filter.button.apply")); btnApply.addActionListener(new java.awt.event.ActionListener() { @Override public void actionPerformed(java.awt.event.ActionEvent e)...
java
private JButton getBtnApply() { if (btnApply == null) { btnApply = new JButton(); btnApply.setText(Constant.messages.getString("history.filter.button.apply")); btnApply.addActionListener(new java.awt.event.ActionListener() { @Override public void actionPerformed(java.awt.event.ActionEvent e)...
[ "private", "JButton", "getBtnApply", "(", ")", "{", "if", "(", "btnApply", "==", "null", ")", "{", "btnApply", "=", "new", "JButton", "(", ")", ";", "btnApply", ".", "setText", "(", "Constant", ".", "messages", ".", "getString", "(", "\"history.filter.butt...
This method initializes btnApply @return javax.swing.JButton
[ "This", "method", "initializes", "btnApply" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/history/HistoryFilterPlusDialog.java#L199-L231
129,440
zaproxy/zaproxy
src/org/zaproxy/zap/extension/history/HistoryFilterPlusDialog.java
HistoryFilterPlusDialog.getBtnReset
private JButton getBtnReset() { if (btnReset == null) { btnReset = new JButton(); btnReset.setText(Constant.messages.getString("history.filter.button.clear")); btnReset.addActionListener(new java.awt.event.ActionListener() { @Override public void actionPerformed(java.awt.event.ActionEvent e)...
java
private JButton getBtnReset() { if (btnReset == null) { btnReset = new JButton(); btnReset.setText(Constant.messages.getString("history.filter.button.clear")); btnReset.addActionListener(new java.awt.event.ActionListener() { @Override public void actionPerformed(java.awt.event.ActionEvent e)...
[ "private", "JButton", "getBtnReset", "(", ")", "{", "if", "(", "btnReset", "==", "null", ")", "{", "btnReset", "=", "new", "JButton", "(", ")", ";", "btnReset", ".", "setText", "(", "Constant", ".", "messages", ".", "getString", "(", "\"history.filter.butt...
This method initializes btnReset @return javax.swing.JButton
[ "This", "method", "initializes", "btnReset" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/history/HistoryFilterPlusDialog.java#L291-L316
129,441
zaproxy/zaproxy
src/org/parosproxy/paros/core/scanner/HostProcess.java
HostProcess.run
@Override public void run() { log.debug("HostProcess.run"); try { hostProcessStartTime = System.currentTimeMillis(); // Initialise plugin factory to report the state of the plugins ASAP. pluginFactory.reset(); synchronized (mapPluginStats) {...
java
@Override public void run() { log.debug("HostProcess.run"); try { hostProcessStartTime = System.currentTimeMillis(); // Initialise plugin factory to report the state of the plugins ASAP. pluginFactory.reset(); synchronized (mapPluginStats) {...
[ "@", "Override", "public", "void", "run", "(", ")", "{", "log", ".", "debug", "(", "\"HostProcess.run\"", ")", ";", "try", "{", "hostProcessStartTime", "=", "System", ".", "currentTimeMillis", "(", ")", ";", "// Initialise plugin factory to report the state of the p...
Main execution method
[ "Main", "execution", "method" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/core/scanner/HostProcess.java#L292-L353
129,442
zaproxy/zaproxy
src/org/parosproxy/paros/core/scanner/HostProcess.java
HostProcess.isStop
public boolean isStop() { if (this.scannerParam.getMaxScanDurationInMins() > 0) { if (System.currentTimeMillis() - this.hostProcessStartTime > TimeUnit.MINUTES.toMillis(this.scannerParam.getMaxScanDurationInMins())) { this.stopReason = Constant.messages.getString("ascan.pro...
java
public boolean isStop() { if (this.scannerParam.getMaxScanDurationInMins() > 0) { if (System.currentTimeMillis() - this.hostProcessStartTime > TimeUnit.MINUTES.toMillis(this.scannerParam.getMaxScanDurationInMins())) { this.stopReason = Constant.messages.getString("ascan.pro...
[ "public", "boolean", "isStop", "(", ")", "{", "if", "(", "this", ".", "scannerParam", ".", "getMaxScanDurationInMins", "(", ")", ">", "0", ")", "{", "if", "(", "System", ".", "currentTimeMillis", "(", ")", "-", "this", ".", "hostProcessStartTime", ">", "...
Check if the current host scan has been stopped @return true if the process has been stopped
[ "Check", "if", "the", "current", "host", "scan", "has", "been", "stopped" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/core/scanner/HostProcess.java#L649-L658
129,443
zaproxy/zaproxy
src/org/parosproxy/paros/core/scanner/HostProcess.java
HostProcess.getRedirectRequestConfig
HttpRequestConfig getRedirectRequestConfig() { if (redirectRequestConfig == null) { redirectRequestConfig = HttpRequestConfig.builder().setRedirectionValidator(getRedirectionValidator()).build(); } return redirectRequestConfig; }
java
HttpRequestConfig getRedirectRequestConfig() { if (redirectRequestConfig == null) { redirectRequestConfig = HttpRequestConfig.builder().setRedirectionValidator(getRedirectionValidator()).build(); } return redirectRequestConfig; }
[ "HttpRequestConfig", "getRedirectRequestConfig", "(", ")", "{", "if", "(", "redirectRequestConfig", "==", "null", ")", "{", "redirectRequestConfig", "=", "HttpRequestConfig", ".", "builder", "(", ")", ".", "setRedirectionValidator", "(", "getRedirectionValidator", "(", ...
Gets the HTTP request configuration that ensures the followed redirections are in scan's scope. @return the HTTP request configuration, never {@code null}. @since TODO add version @see #getRedirectionValidator()
[ "Gets", "the", "HTTP", "request", "configuration", "that", "ensures", "the", "followed", "redirections", "are", "in", "scan", "s", "scope", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/core/scanner/HostProcess.java#L808-L813
129,444
zaproxy/zaproxy
src/org/parosproxy/paros/core/scanner/HostProcess.java
HostProcess.getRedirectionValidator
HttpRedirectionValidator getRedirectionValidator() { if (redirectionValidator == null) { redirectionValidator = redirection -> { if (!nodeInScope(redirection.getEscapedURI())) { if (log.isDebugEnabled()) { log.debug("Skipping redirecti...
java
HttpRedirectionValidator getRedirectionValidator() { if (redirectionValidator == null) { redirectionValidator = redirection -> { if (!nodeInScope(redirection.getEscapedURI())) { if (log.isDebugEnabled()) { log.debug("Skipping redirecti...
[ "HttpRedirectionValidator", "getRedirectionValidator", "(", ")", "{", "if", "(", "redirectionValidator", "==", "null", ")", "{", "redirectionValidator", "=", "redirection", "->", "{", "if", "(", "!", "nodeInScope", "(", "redirection", ".", "getEscapedURI", "(", ")...
Gets the redirection validator that ensures the followed redirections are in scan's scope. @return the redirection validator, never {@code null}. @since TODO add version @see #getRedirectRequestConfig()
[ "Gets", "the", "redirection", "validator", "that", "ensures", "the", "followed", "redirections", "are", "in", "scan", "s", "scope", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/core/scanner/HostProcess.java#L822-L835
129,445
zaproxy/zaproxy
src/org/parosproxy/paros/core/scanner/HostProcess.java
HostProcess.getSkippedReason
public String getSkippedReason(Plugin plugin) { PluginStats pluginStats = mapPluginStats.get(plugin.getId()); if (pluginStats == null) { return stopReason; } return pluginStats.getSkippedReason(); }
java
public String getSkippedReason(Plugin plugin) { PluginStats pluginStats = mapPluginStats.get(plugin.getId()); if (pluginStats == null) { return stopReason; } return pluginStats.getSkippedReason(); }
[ "public", "String", "getSkippedReason", "(", "Plugin", "plugin", ")", "{", "PluginStats", "pluginStats", "=", "mapPluginStats", ".", "get", "(", "plugin", ".", "getId", "(", ")", ")", ";", "if", "(", "pluginStats", "==", "null", ")", "{", "return", "stopRe...
Gets the reason why the given plugin was skipped. @param plugin the plugin that will be checked @return the reason why the given plugin was skipped, might be {@code null} if not skipped or there's no reason @since 2.6.0 @see #isSkipped(Plugin)
[ "Gets", "the", "reason", "why", "the", "given", "plugin", "was", "skipped", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/core/scanner/HostProcess.java#L947-L953
129,446
zaproxy/zaproxy
src/org/parosproxy/paros/core/scanner/HostProcess.java
HostProcess.pluginCompleted
void pluginCompleted(Plugin plugin) { PluginStats pluginStats = mapPluginStats.get(plugin.getId()); if (pluginStats == null) { // Plugin was not processed return; } StringBuilder sb = new StringBuilder(); if (isStop()) { sb.append("st...
java
void pluginCompleted(Plugin plugin) { PluginStats pluginStats = mapPluginStats.get(plugin.getId()); if (pluginStats == null) { // Plugin was not processed return; } StringBuilder sb = new StringBuilder(); if (isStop()) { sb.append("st...
[ "void", "pluginCompleted", "(", "Plugin", "plugin", ")", "{", "PluginStats", "pluginStats", "=", "mapPluginStats", ".", "get", "(", "plugin", ".", "getId", "(", ")", ")", ";", "if", "(", "pluginStats", "==", "null", ")", "{", "// Plugin was not processed\r", ...
Complete the current plugin and update statistics @param plugin the plugin that need to be marked as completed
[ "Complete", "the", "current", "plugin", "and", "update", "statistics" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/core/scanner/HostProcess.java#L959-L997
129,447
zaproxy/zaproxy
src/org/parosproxy/paros/core/scanner/HostProcess.java
HostProcess.setUser
public void setUser(User user) { this.user = user; if (httpSender != null) { httpSender.setUser(user); } }
java
public void setUser(User user) { this.user = user; if (httpSender != null) { httpSender.setUser(user); } }
[ "public", "void", "setUser", "(", "User", "user", ")", "{", "this", ".", "user", "=", "user", ";", "if", "(", "httpSender", "!=", "null", ")", "{", "httpSender", ".", "setUser", "(", "user", ")", ";", "}", "}" ]
Set the user to scan as. If null then the current session will be used. @param user the user to scan as
[ "Set", "the", "user", "to", "scan", "as", ".", "If", "null", "then", "the", "current", "session", "will", "be", "used", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/core/scanner/HostProcess.java#L1032-L1037
129,448
zaproxy/zaproxy
src/org/parosproxy/paros/core/scanner/HostProcess.java
HostProcess.getPluginRequestCount
public int getPluginRequestCount(int pluginId) { PluginStats pluginStats = mapPluginStats.get(pluginId); if (pluginStats != null) { return pluginStats.getMessageCount(); } return 0; }
java
public int getPluginRequestCount(int pluginId) { PluginStats pluginStats = mapPluginStats.get(pluginId); if (pluginStats != null) { return pluginStats.getMessageCount(); } return 0; }
[ "public", "int", "getPluginRequestCount", "(", "int", "pluginId", ")", "{", "PluginStats", "pluginStats", "=", "mapPluginStats", ".", "get", "(", "pluginId", ")", ";", "if", "(", "pluginStats", "!=", "null", ")", "{", "return", "pluginStats", ".", "getMessageC...
Gets the request count of the plugin with the given ID. @param pluginId the ID of the plugin @return the request count @since 2.4.3 @see #getRequestCount()
[ "Gets", "the", "request", "count", "of", "the", "plugin", "with", "the", "given", "ID", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/core/scanner/HostProcess.java#L1124-L1130
129,449
zaproxy/zaproxy
src/org/parosproxy/paros/view/View.java
View.addPanelForContext
private void addPanelForContext(Context context, ContextPanelFactory contextPanelFactory, String[] panelPath) { AbstractContextPropertiesPanel panel = contextPanelFactory.getContextPanel(context); panel.setSessionDialog(getSessionDialog()); getSessionDialog().addParamPanel(panelPath, panel, f...
java
private void addPanelForContext(Context context, ContextPanelFactory contextPanelFactory, String[] panelPath) { AbstractContextPropertiesPanel panel = contextPanelFactory.getContextPanel(context); panel.setSessionDialog(getSessionDialog()); getSessionDialog().addParamPanel(panelPath, panel, f...
[ "private", "void", "addPanelForContext", "(", "Context", "context", ",", "ContextPanelFactory", "contextPanelFactory", ",", "String", "[", "]", "panelPath", ")", "{", "AbstractContextPropertiesPanel", "panel", "=", "contextPanelFactory", ".", "getContextPanel", "(", "co...
Adds a custom context panel for the given context, created form the given context panel factory and placed under the given path. @param contextPanelFactory context panel factory used to create the panel, must not be {@code null} @param panelPath the path where to add the created panel, must not be {@code null} @param ...
[ "Adds", "a", "custom", "context", "panel", "for", "the", "given", "context", "created", "form", "the", "given", "context", "panel", "factory", "and", "placed", "under", "the", "given", "path", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/view/View.java#L764-L776
129,450
zaproxy/zaproxy
src/org/parosproxy/paros/core/scanner/VariantJSONQuery.java
VariantJSONQuery.parseArray
private void parseArray(String fieldName) { int chr; int idx = 0; while (true) { sr.skipWhitespaceRead(); sr.unreadLastCharacter(); parseValue(fieldName + "[" + (idx++) + "]"); chr = sr.skipWhitespaceRead(); if (ch...
java
private void parseArray(String fieldName) { int chr; int idx = 0; while (true) { sr.skipWhitespaceRead(); sr.unreadLastCharacter(); parseValue(fieldName + "[" + (idx++) + "]"); chr = sr.skipWhitespaceRead(); if (ch...
[ "private", "void", "parseArray", "(", "String", "fieldName", ")", "{", "int", "chr", ";", "int", "idx", "=", "0", ";", "while", "(", "true", ")", "{", "sr", ".", "skipWhitespaceRead", "(", ")", ";", "sr", ".", "unreadLastCharacter", "(", ")", ";", "p...
Read a JSON array
[ "Read", "a", "JSON", "array" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/core/scanner/VariantJSONQuery.java#L253-L270
129,451
zaproxy/zaproxy
src/org/zaproxy/zap/extension/spider/SpiderPanelTableModel.java
SpiderPanelTableModel.addScanResult
public void addScanResult(String uri, String method, String flags, boolean skipped) { SpiderScanResult result = new SpiderScanResult(uri, method, flags, !skipped); scanResults.add(result); fireTableRowsInserted(scanResults.size() - 1, scanResults.size() - 1); }
java
public void addScanResult(String uri, String method, String flags, boolean skipped) { SpiderScanResult result = new SpiderScanResult(uri, method, flags, !skipped); scanResults.add(result); fireTableRowsInserted(scanResults.size() - 1, scanResults.size() - 1); }
[ "public", "void", "addScanResult", "(", "String", "uri", ",", "String", "method", ",", "String", "flags", ",", "boolean", "skipped", ")", "{", "SpiderScanResult", "result", "=", "new", "SpiderScanResult", "(", "uri", ",", "method", ",", "flags", ",", "!", ...
Adds a new spider scan result. Method is synchronized internally. @param uri the uri @param method the method @param flags the flags @param skipped {@code true} if the result was skipped, {@code false} otherwise
[ "Adds", "a", "new", "spider", "scan", "result", ".", "Method", "is", "synchronized", "internally", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/spider/SpiderPanelTableModel.java#L121-L125
129,452
zaproxy/zaproxy
src/org/zaproxy/zap/extension/help/ZapTocMerger.java
ZapTocMerger.mergeNodeChildren
public static void mergeNodeChildren(TreeNode node) { DefaultMutableTreeNode masterNode = (DefaultMutableTreeNode) node; // The rules are there are no rules. Nothing else needs to be done // except for merging through the children for (int i = 0; i < masterNode.getChildCount(); i++) { ...
java
public static void mergeNodeChildren(TreeNode node) { DefaultMutableTreeNode masterNode = (DefaultMutableTreeNode) node; // The rules are there are no rules. Nothing else needs to be done // except for merging through the children for (int i = 0; i < masterNode.getChildCount(); i++) { ...
[ "public", "static", "void", "mergeNodeChildren", "(", "TreeNode", "node", ")", "{", "DefaultMutableTreeNode", "masterNode", "=", "(", "DefaultMutableTreeNode", ")", "node", ";", "// The rules are there are no rules. Nothing else needs to be done", "// except for merging through t...
this class instead.
[ "this", "class", "instead", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/help/ZapTocMerger.java#L237-L249
129,453
zaproxy/zaproxy
src/org/zaproxy/zap/extension/search/SearchPanel.java
SearchPanel.getPanelCommand
private javax.swing.JPanel getPanelCommand() { if (panelCommand == null) { panelCommand = new javax.swing.JPanel(); panelCommand.setLayout(new java.awt.GridBagLayout()); panelCommand.setName("Search Panel"); GridBagConstraints gridBagConstraints1 = new GridBagConstraints(); GridBagConstrai...
java
private javax.swing.JPanel getPanelCommand() { if (panelCommand == null) { panelCommand = new javax.swing.JPanel(); panelCommand.setLayout(new java.awt.GridBagLayout()); panelCommand.setName("Search Panel"); GridBagConstraints gridBagConstraints1 = new GridBagConstraints(); GridBagConstrai...
[ "private", "javax", ".", "swing", ".", "JPanel", "getPanelCommand", "(", ")", "{", "if", "(", "panelCommand", "==", "null", ")", "{", "panelCommand", "=", "new", "javax", ".", "swing", ".", "JPanel", "(", ")", ";", "panelCommand", ".", "setLayout", "(", ...
This method initializes panelCommand @return javax.swing.JPanel
[ "This", "method", "initializes", "panelCommand" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/search/SearchPanel.java#L160-L190
129,454
zaproxy/zaproxy
src/org/parosproxy/paros/network/HttpRequestHeader.java
HttpRequestHeader.setMessage
public void setMessage(String data, boolean isSecure) throws HttpMalformedHeaderException { super.setMessage(data); try { parse(isSecure); } catch (HttpMalformedHeaderException e) { mMalformedHeader = true; if (log.isDebugEnabled()) {...
java
public void setMessage(String data, boolean isSecure) throws HttpMalformedHeaderException { super.setMessage(data); try { parse(isSecure); } catch (HttpMalformedHeaderException e) { mMalformedHeader = true; if (log.isDebugEnabled()) {...
[ "public", "void", "setMessage", "(", "String", "data", ",", "boolean", "isSecure", ")", "throws", "HttpMalformedHeaderException", "{", "super", ".", "setMessage", "(", "data", ")", ";", "try", "{", "parse", "(", "isSecure", ")", ";", "}", "catch", "(", "Ht...
Set this request header with the given message. @param data the request header @param isSecure {@code true} if the request should be secure, {@code false} otherwise @throws HttpMalformedHeaderException if the request being set is malformed @see #setSecure(boolean)
[ "Set", "this", "request", "header", "with", "the", "given", "message", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/network/HttpRequestHeader.java#L273-L292
129,455
zaproxy/zaproxy
src/org/parosproxy/paros/network/HttpRequestHeader.java
HttpRequestHeader.setURI
public void setURI(URI uri) throws URIException { if (uri.getScheme() == null || uri.getScheme().equals("")) { mUri = new URI(HTTP + "://" + getHeader(HOST) + "/" + mUri.toString(), true); } else { mUri = uri; } if (uri.getScheme().equalsIg...
java
public void setURI(URI uri) throws URIException { if (uri.getScheme() == null || uri.getScheme().equals("")) { mUri = new URI(HTTP + "://" + getHeader(HOST) + "/" + mUri.toString(), true); } else { mUri = uri; } if (uri.getScheme().equalsIg...
[ "public", "void", "setURI", "(", "URI", "uri", ")", "throws", "URIException", "{", "if", "(", "uri", ".", "getScheme", "(", ")", "==", "null", "||", "uri", ".", "getScheme", "(", ")", ".", "equals", "(", "\"\"", ")", ")", "{", "mUri", "=", "new", ...
Sets the URI of this request header. @param uri the new request URI @throws URIException if an error occurred while setting the request URI
[ "Sets", "the", "URI", "of", "this", "request", "header", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/network/HttpRequestHeader.java#L336-L353
129,456
zaproxy/zaproxy
src/org/parosproxy/paros/network/HttpRequestHeader.java
HttpRequestHeader.setSecure
public void setSecure(boolean isSecure) throws URIException { mIsSecure = isSecure; if (mUri == null) { // mUri not yet set return; } URI newUri = mUri; // check if URI consistent if (isSecure() && mUri.getScheme().equalsIgnoreCase(HT...
java
public void setSecure(boolean isSecure) throws URIException { mIsSecure = isSecure; if (mUri == null) { // mUri not yet set return; } URI newUri = mUri; // check if URI consistent if (isSecure() && mUri.getScheme().equalsIgnoreCase(HT...
[ "public", "void", "setSecure", "(", "boolean", "isSecure", ")", "throws", "URIException", "{", "mIsSecure", "=", "isSecure", ";", "if", "(", "mUri", "==", "null", ")", "{", "// mUri not yet set\r", "return", ";", "}", "URI", "newUri", "=", "mUri", ";", "//...
Sets whether or not the request is done using a secure scheme, HTTPS. @param isSecure {@code true} if the request should be secure, {@code false} otherwise @throws URIException if an error occurred while rebuilding the request URI
[ "Sets", "whether", "or", "not", "the", "request", "is", "done", "using", "a", "secure", "scheme", "HTTPS", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/network/HttpRequestHeader.java#L383-L405
129,457
zaproxy/zaproxy
src/org/parosproxy/paros/network/HttpRequestHeader.java
HttpRequestHeader.parse
private void parse(boolean isSecure) throws URIException, HttpMalformedHeaderException { mIsSecure = isSecure; Matcher matcher = patternRequestLine.matcher(mStartLine); if (!matcher.find()) { mMalformedHeader = true; throw new HttpMalformedHeaderException("Failed t...
java
private void parse(boolean isSecure) throws URIException, HttpMalformedHeaderException { mIsSecure = isSecure; Matcher matcher = patternRequestLine.matcher(mStartLine); if (!matcher.find()) { mMalformedHeader = true; throw new HttpMalformedHeaderException("Failed t...
[ "private", "void", "parse", "(", "boolean", "isSecure", ")", "throws", "URIException", ",", "HttpMalformedHeaderException", "{", "mIsSecure", "=", "isSecure", ";", "Matcher", "matcher", "=", "patternRequestLine", ".", "matcher", "(", "mStartLine", ")", ";", "if", ...
Parse this request header. @param isSecure {@code true} if the request is secure, {@code false} otherwise @throws URIException if failed to parse the URI @throws HttpMalformedHeaderException if the request being parsed is malformed
[ "Parse", "this", "request", "header", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/network/HttpRequestHeader.java#L435-L475
129,458
zaproxy/zaproxy
src/org/parosproxy/paros/network/HttpRequestHeader.java
HttpRequestHeader.getHostName
public String getHostName() { String hostName = mHostName; try { // ZAP: fixed cases, where host name is null hostName = ((mUri.getHost() != null) ? mUri.getHost() : mHostName); } catch (URIException e) { if (log.isDebugEnabled()) { ...
java
public String getHostName() { String hostName = mHostName; try { // ZAP: fixed cases, where host name is null hostName = ((mUri.getHost() != null) ? mUri.getHost() : mHostName); } catch (URIException e) { if (log.isDebugEnabled()) { ...
[ "public", "String", "getHostName", "(", ")", "{", "String", "hostName", "=", "mHostName", ";", "try", "{", "// ZAP: fixed cases, where host name is null\r", "hostName", "=", "(", "(", "mUri", ".", "getHost", "(", ")", "!=", "null", ")", "?", "mUri", ".", "ge...
Get the host name in this request header. @return Host name.
[ "Get", "the", "host", "name", "in", "this", "request", "header", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/network/HttpRequestHeader.java#L504-L517
129,459
zaproxy/zaproxy
src/org/parosproxy/paros/network/HttpRequestHeader.java
HttpRequestHeader.isImage
@Override public boolean isImage() { if (getURI() == null) { return false; } try { // ZAP: prevents a NullPointerException when no path exists final String path = getURI().getPath(); if (path != null) { return (patter...
java
@Override public boolean isImage() { if (getURI() == null) { return false; } try { // ZAP: prevents a NullPointerException when no path exists final String path = getURI().getPath(); if (path != null) { return (patter...
[ "@", "Override", "public", "boolean", "isImage", "(", ")", "{", "if", "(", "getURI", "(", ")", "==", "null", ")", "{", "return", "false", ";", "}", "try", "{", "// ZAP: prevents a NullPointerException when no path exists\r", "final", "String", "path", "=", "ge...
Return if this request header is a image request basing on the path suffix.
[ "Return", "if", "this", "request", "header", "is", "a", "image", "request", "basing", "on", "the", "path", "suffix", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/network/HttpRequestHeader.java#L563-L581
129,460
zaproxy/zaproxy
src/org/parosproxy/paros/network/HttpRequestHeader.java
HttpRequestHeader.setGetParams
public void setGetParams(TreeSet<HtmlParameter> getParams) { if (mUri == null) { return; } if (getParams.isEmpty()) { try { mUri.setQuery(""); } catch (URIException e) { log.error(e.getMessage(), e); ...
java
public void setGetParams(TreeSet<HtmlParameter> getParams) { if (mUri == null) { return; } if (getParams.isEmpty()) { try { mUri.setQuery(""); } catch (URIException e) { log.error(e.getMessage(), e); ...
[ "public", "void", "setGetParams", "(", "TreeSet", "<", "HtmlParameter", ">", "getParams", ")", "{", "if", "(", "mUri", "==", "null", ")", "{", "return", ";", "}", "if", "(", "getParams", ".", "isEmpty", "(", ")", ")", "{", "try", "{", "mUri", ".", ...
Based on getParams
[ "Based", "on", "getParams" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/network/HttpRequestHeader.java#L673-L722
129,461
zaproxy/zaproxy
src/org/parosproxy/paros/network/HttpRequestHeader.java
HttpRequestHeader.setCookieParams
public void setCookieParams(TreeSet<HtmlParameter> cookieParams) { if (cookieParams.isEmpty()) { setHeader(HttpHeader.COOKIE, null); } StringBuilder sbData = new StringBuilder(); for (HtmlParameter parameter : cookieParams) { if (parameter.getType() != H...
java
public void setCookieParams(TreeSet<HtmlParameter> cookieParams) { if (cookieParams.isEmpty()) { setHeader(HttpHeader.COOKIE, null); } StringBuilder sbData = new StringBuilder(); for (HtmlParameter parameter : cookieParams) { if (parameter.getType() != H...
[ "public", "void", "setCookieParams", "(", "TreeSet", "<", "HtmlParameter", ">", "cookieParams", ")", "{", "if", "(", "cookieParams", ".", "isEmpty", "(", ")", ")", "{", "setHeader", "(", "HttpHeader", ".", "COOKIE", ",", "null", ")", ";", "}", "StringBuild...
based on cookieParams
[ "based", "on", "cookieParams" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/network/HttpRequestHeader.java#L754-L782
129,462
zaproxy/zaproxy
src/org/parosproxy/paros/network/HttpRequestHeader.java
HttpRequestHeader.getHttpCookies
public List<HttpCookie> getHttpCookies() { List<HttpCookie> cookies = new LinkedList<>(); // Use getCookieParams to reduce the places we parse cookies TreeSet<HtmlParameter> ts = getCookieParams(); Iterator<HtmlParameter> it = ts.iterator(); while (it.hasNext()) { ...
java
public List<HttpCookie> getHttpCookies() { List<HttpCookie> cookies = new LinkedList<>(); // Use getCookieParams to reduce the places we parse cookies TreeSet<HtmlParameter> ts = getCookieParams(); Iterator<HtmlParameter> it = ts.iterator(); while (it.hasNext()) { ...
[ "public", "List", "<", "HttpCookie", ">", "getHttpCookies", "(", ")", "{", "List", "<", "HttpCookie", ">", "cookies", "=", "new", "LinkedList", "<>", "(", ")", ";", "// Use getCookieParams to reduce the places we parse cookies\r", "TreeSet", "<", "HtmlParameter", ">...
Gets a list of the http cookies from this request Header. @return the http cookies @throws IllegalArgumentException if a problem is encountered while processing the "Cookie: " header line.
[ "Gets", "a", "list", "of", "the", "http", "cookies", "from", "this", "request", "Header", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/network/HttpRequestHeader.java#L820-L839
129,463
zaproxy/zaproxy
src/org/zaproxy/zap/extension/history/ManageTagsDialog.java
ManageTagsDialog.getBtnDelete
private JButton getBtnDelete() { if (btnDelete == null) { btnDelete = new JButton(); btnDelete.setText(Constant.messages.getString("history.managetags.button.delete")); btnDelete.setMinimumSize(new java.awt.Dimension(75,30)); btnDelete.setPreferredSize(new java.awt.Dimension(75,30)); btnDelete.se...
java
private JButton getBtnDelete() { if (btnDelete == null) { btnDelete = new JButton(); btnDelete.setText(Constant.messages.getString("history.managetags.button.delete")); btnDelete.setMinimumSize(new java.awt.Dimension(75,30)); btnDelete.setPreferredSize(new java.awt.Dimension(75,30)); btnDelete.se...
[ "private", "JButton", "getBtnDelete", "(", ")", "{", "if", "(", "btnDelete", "==", "null", ")", "{", "btnDelete", "=", "new", "JButton", "(", ")", ";", "btnDelete", ".", "setText", "(", "Constant", ".", "messages", ".", "getString", "(", "\"history.managet...
This method initializes btnDelete @return javax.swing.JButton
[ "This", "method", "initializes", "btnDelete" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/history/ManageTagsDialog.java#L266-L284
129,464
zaproxy/zaproxy
src/org/zaproxy/zap/spider/SpiderTask.java
SpiderTask.fetchResource
private void fetchResource(HttpMessage msg) throws IOException { if (parent.getHttpSender() == null) { return; } try { parent.getHttpSender().sendAndReceive(msg); } catch (ConnectException e) { log.debug("Failed to connect to: " + msg.getRequestHeader().getURI(), e); throw e; } catch (SocketTim...
java
private void fetchResource(HttpMessage msg) throws IOException { if (parent.getHttpSender() == null) { return; } try { parent.getHttpSender().sendAndReceive(msg); } catch (ConnectException e) { log.debug("Failed to connect to: " + msg.getRequestHeader().getURI(), e); throw e; } catch (SocketTim...
[ "private", "void", "fetchResource", "(", "HttpMessage", "msg", ")", "throws", "IOException", "{", "if", "(", "parent", ".", "getHttpSender", "(", ")", "==", "null", ")", "{", "return", ";", "}", "try", "{", "parent", ".", "getHttpSender", "(", ")", ".", ...
Fetches a resource. @param msg the HTTP message that will be sent to the server @throws IOException Signals that an I/O exception has occurred.
[ "Fetches", "a", "resource", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/spider/SpiderTask.java#L414-L438
129,465
zaproxy/zaproxy
src/org/zaproxy/zap/extension/autoupdate/ExtensionAutoUpdate.java
ExtensionAutoUpdate.getMenuItemCheckUpdate
private ZapMenuItem getMenuItemCheckUpdate() { if (menuItemCheckUpdate == null) { menuItemCheckUpdate = new ZapMenuItem("cfu.help.menu.check", getView().getMenuShortcutKeyStroke(KeyEvent.VK_U, 0, false)); menuItemCheckUpdate.setText(Constant.messages.getString("cfu.help.menu.check")); menuItemCheckUpda...
java
private ZapMenuItem getMenuItemCheckUpdate() { if (menuItemCheckUpdate == null) { menuItemCheckUpdate = new ZapMenuItem("cfu.help.menu.check", getView().getMenuShortcutKeyStroke(KeyEvent.VK_U, 0, false)); menuItemCheckUpdate.setText(Constant.messages.getString("cfu.help.menu.check")); menuItemCheckUpda...
[ "private", "ZapMenuItem", "getMenuItemCheckUpdate", "(", ")", "{", "if", "(", "menuItemCheckUpdate", "==", "null", ")", "{", "menuItemCheckUpdate", "=", "new", "ZapMenuItem", "(", "\"cfu.help.menu.check\"", ",", "getView", "(", ")", ".", "getMenuShortcutKeyStroke", ...
This method initializes menuItemEncoder @return javax.swing.JMenuItem
[ "This", "method", "initializes", "menuItemEncoder" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/autoupdate/ExtensionAutoUpdate.java#L196-L210
129,466
zaproxy/zaproxy
src/org/zaproxy/zap/extension/autoupdate/ExtensionAutoUpdate.java
ExtensionAutoUpdate.processAddOnChanges
void processAddOnChanges(Window caller, AddOnDependencyChecker.AddOnChangesResult changes) { if (addonsDialog != null) { addonsDialog.setDownloadingUpdates(); } if (getView() != null) { Set<AddOn> addOns = new HashSet<>(changes.getUninstalls()); addOns.addAll...
java
void processAddOnChanges(Window caller, AddOnDependencyChecker.AddOnChangesResult changes) { if (addonsDialog != null) { addonsDialog.setDownloadingUpdates(); } if (getView() != null) { Set<AddOn> addOns = new HashSet<>(changes.getUninstalls()); addOns.addAll...
[ "void", "processAddOnChanges", "(", "Window", "caller", ",", "AddOnDependencyChecker", ".", "AddOnChangesResult", "changes", ")", "{", "if", "(", "addonsDialog", "!=", "null", ")", "{", "addonsDialog", ".", "setDownloadingUpdates", "(", ")", ";", "}", "if", "(",...
Processes the given add-on changes. @param caller the caller to set as parent of shown dialogues @param changes the changes that will be processed
[ "Processes", "the", "given", "add", "-", "on", "changes", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/autoupdate/ExtensionAutoUpdate.java#L1336-L1365
129,467
zaproxy/zaproxy
src/org/zaproxy/zap/extension/autoupdate/ExtensionAutoUpdate.java
ExtensionAutoUpdate.installAddOns
public synchronized String installAddOns(List<String> addons) { StringBuilder errorMessages = new StringBuilder(); AddOnCollection aoc = getLatestVersionInfo(); if (aoc == null) { String error = Constant.messages.getString("cfu.cmdline.nocfu"); errorMessages.append(error)...
java
public synchronized String installAddOns(List<String> addons) { StringBuilder errorMessages = new StringBuilder(); AddOnCollection aoc = getLatestVersionInfo(); if (aoc == null) { String error = Constant.messages.getString("cfu.cmdline.nocfu"); errorMessages.append(error)...
[ "public", "synchronized", "String", "installAddOns", "(", "List", "<", "String", ">", "addons", ")", "{", "StringBuilder", "errorMessages", "=", "new", "StringBuilder", "(", ")", ";", "AddOnCollection", "aoc", "=", "getLatestVersionInfo", "(", ")", ";", "if", ...
Installs the specified add-ons @param addons The identifiers of the add-ons to be installed @return A string containing any error messages, will be empty if there were no problems
[ "Installs", "the", "specified", "add", "-", "ons" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/autoupdate/ExtensionAutoUpdate.java#L1686-L1741
129,468
zaproxy/zaproxy
src/org/zaproxy/zap/extension/autoupdate/ExtensionAutoUpdate.java
ExtensionAutoUpdate.uninstallAddOns
public synchronized String uninstallAddOns(List<String> addons) { StringBuilder errorMessages = new StringBuilder(); AddOnCollection aoc = this.getLocalVersionInfo(); if (aoc == null) { String error = Constant.messages.getString("cfu.cmdline.nocfu"); errorMessages.append(...
java
public synchronized String uninstallAddOns(List<String> addons) { StringBuilder errorMessages = new StringBuilder(); AddOnCollection aoc = this.getLocalVersionInfo(); if (aoc == null) { String error = Constant.messages.getString("cfu.cmdline.nocfu"); errorMessages.append(...
[ "public", "synchronized", "String", "uninstallAddOns", "(", "List", "<", "String", ">", "addons", ")", "{", "StringBuilder", "errorMessages", "=", "new", "StringBuilder", "(", ")", ";", "AddOnCollection", "aoc", "=", "this", ".", "getLocalVersionInfo", "(", ")",...
Uninstalls the specified add-ons @param addons The identifiers of the add-ons to be installed @return A string containing any error messages, will be empty if there were no problems
[ "Uninstalls", "the", "specified", "add", "-", "ons" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/autoupdate/ExtensionAutoUpdate.java#L1748-L1796
129,469
zaproxy/zaproxy
src/org/zaproxy/zap/view/MainToolbarPanel.java
MainToolbarPanel.removeToolBarComponent
public void removeToolBarComponent(Component component) { validateComponentNonNull(component); getToolbar().remove(component); getToolbar().validate(); getToolbar().repaint(); }
java
public void removeToolBarComponent(Component component) { validateComponentNonNull(component); getToolbar().remove(component); getToolbar().validate(); getToolbar().repaint(); }
[ "public", "void", "removeToolBarComponent", "(", "Component", "component", ")", "{", "validateComponentNonNull", "(", "component", ")", ";", "getToolbar", "(", ")", ".", "remove", "(", "component", ")", ";", "getToolbar", "(", ")", ".", "validate", "(", ")", ...
Removes the given component to the tool bar. @param component the component to remove. @throws IllegalArgumentException if the component is {@code null}. @since 2.6.0
[ "Removes", "the", "given", "component", "to", "the", "tool", "bar", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/view/MainToolbarPanel.java#L160-L166
129,470
zaproxy/zaproxy
src/org/zaproxy/zap/extension/search/SearchParam.java
SearchParam.setMaximumSearchResultsGUI
public void setMaximumSearchResultsGUI(int maximumSearchResultsGUI) { if (this.maximumSearchResultsGUI != maximumSearchResultsGUI) { this.maximumSearchResultsGUI = maximumSearchResultsGUI; getConfig().setProperty(PARAM_MAXIMUM_RESULTS_GUI, maximumSearchResultsGUI); } }
java
public void setMaximumSearchResultsGUI(int maximumSearchResultsGUI) { if (this.maximumSearchResultsGUI != maximumSearchResultsGUI) { this.maximumSearchResultsGUI = maximumSearchResultsGUI; getConfig().setProperty(PARAM_MAXIMUM_RESULTS_GUI, maximumSearchResultsGUI); } }
[ "public", "void", "setMaximumSearchResultsGUI", "(", "int", "maximumSearchResultsGUI", ")", "{", "if", "(", "this", ".", "maximumSearchResultsGUI", "!=", "maximumSearchResultsGUI", ")", "{", "this", ".", "maximumSearchResultsGUI", "=", "maximumSearchResultsGUI", ";", "g...
Sets whether the number of maximum results that should be shown in the results panel. @param maximumSearchResultsGUI the number of maximum results that should be shown in the results panel @see #getMaximumSearchResultsGUI()
[ "Sets", "whether", "the", "number", "of", "maximum", "results", "that", "should", "be", "shown", "in", "the", "results", "panel", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/search/SearchParam.java#L82-L88
129,471
zaproxy/zaproxy
src/org/zaproxy/zap/extension/api/WikiAPIGenerator.java
WikiAPIGenerator.generateAPIFiles
@Override public void generateAPIFiles(List<ApiImplementor> implementors) throws IOException { // Generate index first this.generateWikiIndex(); for (ApiImplementor imp : implementors) { this.generateAPIFiles(imp); } this.methods = 0; this.generateWikiFull(); System.out.println("Generated a total of "...
java
@Override public void generateAPIFiles(List<ApiImplementor> implementors) throws IOException { // Generate index first this.generateWikiIndex(); for (ApiImplementor imp : implementors) { this.generateAPIFiles(imp); } this.methods = 0; this.generateWikiFull(); System.out.println("Generated a total of "...
[ "@", "Override", "public", "void", "generateAPIFiles", "(", "List", "<", "ApiImplementor", ">", "implementors", ")", "throws", "IOException", "{", "// Generate index first", "this", ".", "generateWikiIndex", "(", ")", ";", "for", "(", "ApiImplementor", "imp", ":",...
Generates the wiki files of the given API implementors.
[ "Generates", "the", "wiki", "files", "of", "the", "given", "API", "implementors", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/api/WikiAPIGenerator.java#L112-L122
129,472
zaproxy/zaproxy
src/org/zaproxy/zap/extension/sessions/ExtensionSessionManagement.java
ExtensionSessionManagement.loadSesssionManagementMethodTypes
private void loadSesssionManagementMethodTypes(ExtensionHook extensionHook) { this.sessionManagementMethodTypes = new ArrayList<>(); this.sessionManagementMethodTypes.add(new CookieBasedSessionManagementMethodType()); this.sessionManagementMethodTypes.add(new HttpAuthSessionManagementMethodType()); for (Sessio...
java
private void loadSesssionManagementMethodTypes(ExtensionHook extensionHook) { this.sessionManagementMethodTypes = new ArrayList<>(); this.sessionManagementMethodTypes.add(new CookieBasedSessionManagementMethodType()); this.sessionManagementMethodTypes.add(new HttpAuthSessionManagementMethodType()); for (Sessio...
[ "private", "void", "loadSesssionManagementMethodTypes", "(", "ExtensionHook", "extensionHook", ")", "{", "this", ".", "sessionManagementMethodTypes", "=", "new", "ArrayList", "<>", "(", ")", ";", "this", ".", "sessionManagementMethodTypes", ".", "add", "(", "new", "...
Loads session management method types and hooks them up. @param extensionHook the extension hook
[ "Loads", "session", "management", "method", "types", "and", "hooks", "them", "up", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/sessions/ExtensionSessionManagement.java#L145-L157
129,473
zaproxy/zaproxy
src/org/zaproxy/zap/extension/sessions/ExtensionSessionManagement.java
ExtensionSessionManagement.getSessionManagementMethodTypeForIdentifier
public SessionManagementMethodType getSessionManagementMethodTypeForIdentifier(int id) { for (SessionManagementMethodType t : getSessionManagementMethodTypes()) if (t.getUniqueIdentifier() == id) return t; return null; }
java
public SessionManagementMethodType getSessionManagementMethodTypeForIdentifier(int id) { for (SessionManagementMethodType t : getSessionManagementMethodTypes()) if (t.getUniqueIdentifier() == id) return t; return null; }
[ "public", "SessionManagementMethodType", "getSessionManagementMethodTypeForIdentifier", "(", "int", "id", ")", "{", "for", "(", "SessionManagementMethodType", "t", ":", "getSessionManagementMethodTypes", "(", ")", ")", "if", "(", "t", ".", "getUniqueIdentifier", "(", ")...
Gets the session management method type for a given identifier. @param id the id @return the session management method type for identifier
[ "Gets", "the", "session", "management", "method", "type", "for", "a", "given", "identifier", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/sessions/ExtensionSessionManagement.java#L175-L180
129,474
zaproxy/zaproxy
src/org/zaproxy/zap/control/AddOnInstaller.java
AddOnInstaller.uninstallAddOnExtension
protected static boolean uninstallAddOnExtension( AddOn addOn, Extension extension, AddOnUninstallationProgressCallback callback) { boolean uninstalledWithoutErrors = true; if (extension.isEnabled()) { String extUiName = extension.getUIName(); ...
java
protected static boolean uninstallAddOnExtension( AddOn addOn, Extension extension, AddOnUninstallationProgressCallback callback) { boolean uninstalledWithoutErrors = true; if (extension.isEnabled()) { String extUiName = extension.getUIName(); ...
[ "protected", "static", "boolean", "uninstallAddOnExtension", "(", "AddOn", "addOn", ",", "Extension", "extension", ",", "AddOnUninstallationProgressCallback", "callback", ")", "{", "boolean", "uninstalledWithoutErrors", "=", "true", ";", "if", "(", "extension", ".", "...
Uninstalls the given extension. @param addOn the add-on that has the extension @param extension the extension that should be uninstalled @param callback the callback that will be notified of the progress of the uninstallation @return {@code true} if the extension was uninstalled without errors, {@code false} otherwise...
[ "Uninstalls", "the", "given", "extension", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/control/AddOnInstaller.java#L310-L339
129,475
zaproxy/zaproxy
src/org/zaproxy/zap/control/AddOnInstaller.java
AddOnInstaller.uninstallAddOnFiles
@Deprecated public static boolean uninstallAddOnFiles(AddOn addOn, AddOnUninstallationProgressCallback callback) { return uninstallAddOnFiles(addOn, callback, null); }
java
@Deprecated public static boolean uninstallAddOnFiles(AddOn addOn, AddOnUninstallationProgressCallback callback) { return uninstallAddOnFiles(addOn, callback, null); }
[ "@", "Deprecated", "public", "static", "boolean", "uninstallAddOnFiles", "(", "AddOn", "addOn", ",", "AddOnUninstallationProgressCallback", "callback", ")", "{", "return", "uninstallAddOnFiles", "(", "addOn", ",", "callback", ",", "null", ")", ";", "}" ]
Uninstalls the files of the given add-on. @param addOn the add-on @param callback the callback for notification of progress @return {@code true} if no error occurred while removing the files, {@code false} otherwise. @throws IllegalArgumentException if {@code addOn} or {@code callback} are null. @deprecated (TODO add ...
[ "Uninstalls", "the", "files", "of", "the", "given", "add", "-", "on", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/control/AddOnInstaller.java#L489-L492
129,476
zaproxy/zaproxy
src/org/zaproxy/zap/ZapBootstrap.java
ZapBootstrap.start
public int start() { // Nasty hack to prevent warning messages when running from the command line NullAppender na = new NullAppender(); Logger.getRootLogger().addAppender(na); Logger.getRootLogger().setLevel(Level.OFF); Logger.getLogger(ConfigurationUtils.class).addAppender(na); ...
java
public int start() { // Nasty hack to prevent warning messages when running from the command line NullAppender na = new NullAppender(); Logger.getRootLogger().addAppender(na); Logger.getRootLogger().setLevel(Level.OFF); Logger.getLogger(ConfigurationUtils.class).addAppender(na); ...
[ "public", "int", "start", "(", ")", "{", "// Nasty hack to prevent warning messages when running from the command line", "NullAppender", "na", "=", "new", "NullAppender", "(", ")", ";", "Logger", ".", "getRootLogger", "(", ")", ".", "addAppender", "(", "na", ")", ";...
Starts the bootstrap process. @return the return code of the program
[ "Starts", "the", "bootstrap", "process", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/ZapBootstrap.java#L67-L85
129,477
zaproxy/zaproxy
src/org/zaproxy/zap/ZapBootstrap.java
ZapBootstrap.getStartingMessage
protected static String getStartingMessage() { DateFormat dateFormat = SimpleDateFormat.getDateTimeInstance(DateFormat.SHORT, DateFormat.MEDIUM); StringBuilder strBuilder = new StringBuilder(200); strBuilder.append(Constant.PROGRAM_NAME).append(' ').append(Constant.PROGRAM_VERSION); strB...
java
protected static String getStartingMessage() { DateFormat dateFormat = SimpleDateFormat.getDateTimeInstance(DateFormat.SHORT, DateFormat.MEDIUM); StringBuilder strBuilder = new StringBuilder(200); strBuilder.append(Constant.PROGRAM_NAME).append(' ').append(Constant.PROGRAM_VERSION); strB...
[ "protected", "static", "String", "getStartingMessage", "(", ")", "{", "DateFormat", "dateFormat", "=", "SimpleDateFormat", ".", "getDateTimeInstance", "(", "DateFormat", ".", "SHORT", ",", "DateFormat", ".", "MEDIUM", ")", ";", "StringBuilder", "strBuilder", "=", ...
Gets ZAP's starting message. @return the starting message
[ "Gets", "ZAP", "s", "starting", "message", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/ZapBootstrap.java#L124-L132
129,478
zaproxy/zaproxy
src/org/zaproxy/zap/view/panels/AbstractContextSelectToolbarStatusPanel.java
AbstractContextSelectToolbarStatusPanel.getContextSelectComboBox
protected ContextSelectComboBox getContextSelectComboBox() { if (contextSelectBox == null) { contextSelectBox = new ContextSelectComboBox(); contextSelectBox.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { contextSelected((Context) contextSelectBox.ge...
java
protected ContextSelectComboBox getContextSelectComboBox() { if (contextSelectBox == null) { contextSelectBox = new ContextSelectComboBox(); contextSelectBox.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { contextSelected((Context) contextSelectBox.ge...
[ "protected", "ContextSelectComboBox", "getContextSelectComboBox", "(", ")", "{", "if", "(", "contextSelectBox", "==", "null", ")", "{", "contextSelectBox", "=", "new", "ContextSelectComboBox", "(", ")", ";", "contextSelectBox", ".", "addActionListener", "(", "new", ...
Gets the Context select combo box. @return the context select combo box
[ "Gets", "the", "Context", "select", "combo", "box", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/view/panels/AbstractContextSelectToolbarStatusPanel.java#L167-L178
129,479
zaproxy/zaproxy
src/org/zaproxy/zap/utils/ViewState.java
ViewState.encode
public static String encode(Serializable o) { ByteArrayOutputStream bos = new ByteArrayOutputStream(); try { ObjectOutputStream oos = new ObjectOutputStream(bos); try { oos.writeObject(o); ...
java
public static String encode(Serializable o) { ByteArrayOutputStream bos = new ByteArrayOutputStream(); try { ObjectOutputStream oos = new ObjectOutputStream(bos); try { oos.writeObject(o); ...
[ "public", "static", "String", "encode", "(", "Serializable", "o", ")", "{", "ByteArrayOutputStream", "bos", "=", "new", "ByteArrayOutputStream", "(", ")", ";", "try", "{", "ObjectOutputStream", "oos", "=", "new", "ObjectOutputStream", "(", "bos", ")", ";", "tr...
encode a object to a base64 string @param o is a implemented java.io.Serializable object @return the encoded object
[ "encode", "a", "object", "to", "a", "base64", "string" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/utils/ViewState.java#L61-L75
129,480
zaproxy/zaproxy
src/org/zaproxy/zap/utils/ViewState.java
ViewState.decode
@SuppressWarnings("unchecked") public static <T> T decode(String base64) { //BASE64Decoder decoder = new BASE64Decoder(); try { //byte[] b = decoder.decodeBuffer(base64); byte[] b = Base64.decode(bas...
java
@SuppressWarnings("unchecked") public static <T> T decode(String base64) { //BASE64Decoder decoder = new BASE64Decoder(); try { //byte[] b = decoder.decodeBuffer(base64); byte[] b = Base64.decode(bas...
[ "@", "SuppressWarnings", "(", "\"unchecked\"", ")", "public", "static", "<", "T", ">", "T", "decode", "(", "String", "base64", ")", "{", "//BASE64Decoder decoder = new BASE64Decoder();\r", "try", "{", "//byte[] b = decoder.decodeBuffer(base64);\r", "byte", ...
decode a base64 string to a object @param <T> the type of the object @param base64 a encoded string by ViewState.encode method @return the decoded object
[ "decode", "a", "base64", "string", "to", "a", "object" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/utils/ViewState.java#L83-L95
129,481
zaproxy/zaproxy
src/org/zaproxy/zap/extension/alert/AlertPanel.java
AlertPanel.getPaneScroll
private JScrollPane getPaneScroll() { if (paneScroll == null) { paneScroll = new JScrollPane(); paneScroll.setName("paneScroll"); paneScroll.setViewportView(getTreeAlert()); } return paneScroll; }
java
private JScrollPane getPaneScroll() { if (paneScroll == null) { paneScroll = new JScrollPane(); paneScroll.setName("paneScroll"); paneScroll.setViewportView(getTreeAlert()); } return paneScroll; }
[ "private", "JScrollPane", "getPaneScroll", "(", ")", "{", "if", "(", "paneScroll", "==", "null", ")", "{", "paneScroll", "=", "new", "JScrollPane", "(", ")", ";", "paneScroll", ".", "setName", "(", "\"paneScroll\"", ")", ";", "paneScroll", ".", "setViewportV...
This method initializes paneScroll @return javax.swing.JScrollPane
[ "This", "method", "initializes", "paneScroll" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/alert/AlertPanel.java#L595-L602
129,482
zaproxy/zaproxy
src/org/parosproxy/paros/view/MainMenuBar.java
MainMenuBar.getMenuImport
public javax.swing.JMenu getMenuImport() { if (menuImport == null) { menuImport = new javax.swing.JMenu(); menuImport.setText(Constant.messages.getString("menu.import")); menuImport.setMnemonic(Constant.messages.getChar("menu.import.mnemonic")); } return menuImport; }
java
public javax.swing.JMenu getMenuImport() { if (menuImport == null) { menuImport = new javax.swing.JMenu(); menuImport.setText(Constant.messages.getString("menu.import")); menuImport.setMnemonic(Constant.messages.getChar("menu.import.mnemonic")); } return menuImport; }
[ "public", "javax", ".", "swing", ".", "JMenu", "getMenuImport", "(", ")", "{", "if", "(", "menuImport", "==", "null", ")", "{", "menuImport", "=", "new", "javax", ".", "swing", ".", "JMenu", "(", ")", ";", "menuImport", ".", "setText", "(", "Constant",...
This method initializes menuImport @return javax.swing.JMenu @since TODO Add Version
[ "This", "method", "initializes", "menuImport" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/view/MainMenuBar.java#L223-L230
129,483
zaproxy/zaproxy
src/org/parosproxy/paros/view/MainMenuBar.java
MainMenuBar.getMenuFileProperties
private ZapMenuItem getMenuFileProperties() { if (menuFileProperties == null) { menuFileProperties = new ZapMenuItem("menu.file.properties", View.getSingleton().getMenuShortcutKeyStroke(KeyEvent.VK_P, KeyEvent.ALT_DOWN_MASK, false)); menuFileProperties.setText(Constant.messages.getString("menu.file.pro...
java
private ZapMenuItem getMenuFileProperties() { if (menuFileProperties == null) { menuFileProperties = new ZapMenuItem("menu.file.properties", View.getSingleton().getMenuShortcutKeyStroke(KeyEvent.VK_P, KeyEvent.ALT_DOWN_MASK, false)); menuFileProperties.setText(Constant.messages.getString("menu.file.pro...
[ "private", "ZapMenuItem", "getMenuFileProperties", "(", ")", "{", "if", "(", "menuFileProperties", "==", "null", ")", "{", "menuFileProperties", "=", "new", "ZapMenuItem", "(", "\"menu.file.properties\"", ",", "View", ".", "getSingleton", "(", ")", ".", "getMenuSh...
This method initializes menuFileProperties @return javax.swing.JMenuItem
[ "This", "method", "initializes", "menuFileProperties" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/view/MainMenuBar.java#L452-L466
129,484
zaproxy/zaproxy
src/org/parosproxy/paros/view/MainMenuBar.java
MainMenuBar.getMenuHelp
public JMenu getMenuHelp() { if (menuHelp == null) { menuHelp = new JMenu(); menuHelp.setText(Constant.messages.getString("menu.help")); // ZAP: i18n menuHelp.setMnemonic(Constant.messages.getChar("menu.help.mnemonic")); menuHelp.add(getMenuHelpAbout()); menuHelp.add(getMenuHelpSupport()); } ...
java
public JMenu getMenuHelp() { if (menuHelp == null) { menuHelp = new JMenu(); menuHelp.setText(Constant.messages.getString("menu.help")); // ZAP: i18n menuHelp.setMnemonic(Constant.messages.getChar("menu.help.mnemonic")); menuHelp.add(getMenuHelpAbout()); menuHelp.add(getMenuHelpSupport()); } ...
[ "public", "JMenu", "getMenuHelp", "(", ")", "{", "if", "(", "menuHelp", "==", "null", ")", "{", "menuHelp", "=", "new", "JMenu", "(", ")", ";", "menuHelp", ".", "setText", "(", "Constant", ".", "messages", ".", "getString", "(", "\"menu.help\"", ")", "...
This method initializes menuHelp @return javax.swing.JMenu
[ "This", "method", "initializes", "menuHelp" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/view/MainMenuBar.java#L499-L508
129,485
zaproxy/zaproxy
src/org/parosproxy/paros/view/MainMenuBar.java
MainMenuBar.getMenuHelpAbout
private ZapMenuItem getMenuHelpAbout() { if (menuHelpAbout == null) { menuHelpAbout = new ZapMenuItem("menu.help.about"); menuHelpAbout.addActionListener(new java.awt.event.ActionListener() { @Override public void actionPerformed(java.awt.event.ActionEvent e) { AboutDialog dialog = new A...
java
private ZapMenuItem getMenuHelpAbout() { if (menuHelpAbout == null) { menuHelpAbout = new ZapMenuItem("menu.help.about"); menuHelpAbout.addActionListener(new java.awt.event.ActionListener() { @Override public void actionPerformed(java.awt.event.ActionEvent e) { AboutDialog dialog = new A...
[ "private", "ZapMenuItem", "getMenuHelpAbout", "(", ")", "{", "if", "(", "menuHelpAbout", "==", "null", ")", "{", "menuHelpAbout", "=", "new", "ZapMenuItem", "(", "\"menu.help.about\"", ")", ";", "menuHelpAbout", ".", "addActionListener", "(", "new", "java", ".",...
This method initializes menuHelpAbout @return javax.swing.ZapMenuItem
[ "This", "method", "initializes", "menuHelpAbout" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/view/MainMenuBar.java#L533-L546
129,486
zaproxy/zaproxy
src/org/parosproxy/paros/view/MainMenuBar.java
MainMenuBar.getMenuAnalyse
public JMenu getMenuAnalyse() { if (menuAnalyse == null) { menuAnalyse = new JMenu(); menuAnalyse.setText(Constant.messages.getString("menu.analyse")); // ZAP: i18n menuAnalyse.setMnemonic(Constant.messages.getChar("menu.analyse.mnemonic")); } return menuAnalyse;...
java
public JMenu getMenuAnalyse() { if (menuAnalyse == null) { menuAnalyse = new JMenu(); menuAnalyse.setText(Constant.messages.getString("menu.analyse")); // ZAP: i18n menuAnalyse.setMnemonic(Constant.messages.getChar("menu.analyse.mnemonic")); } return menuAnalyse;...
[ "public", "JMenu", "getMenuAnalyse", "(", ")", "{", "if", "(", "menuAnalyse", "==", "null", ")", "{", "menuAnalyse", "=", "new", "JMenu", "(", ")", ";", "menuAnalyse", ".", "setText", "(", "Constant", ".", "messages", ".", "getString", "(", "\"menu.analyse...
This method initializes jMenu1 @return javax.swing.JMenu
[ "This", "method", "initializes", "jMenu1" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/view/MainMenuBar.java#L567-L574
129,487
zaproxy/zaproxy
src/org/zaproxy/zap/extension/pscan/PassiveScannerList.java
PassiveScannerList.getScanner
public PassiveScanner getScanner(int pluginId) { for (PassiveScanner scanner : passiveScanners) { if (scanner instanceof PluginPassiveScanner) { if (((PluginPassiveScanner)scanner).getPluginId() == pluginId) { return scanner; } } ...
java
public PassiveScanner getScanner(int pluginId) { for (PassiveScanner scanner : passiveScanners) { if (scanner instanceof PluginPassiveScanner) { if (((PluginPassiveScanner)scanner).getPluginId() == pluginId) { return scanner; } } ...
[ "public", "PassiveScanner", "getScanner", "(", "int", "pluginId", ")", "{", "for", "(", "PassiveScanner", "scanner", ":", "passiveScanners", ")", "{", "if", "(", "scanner", "instanceof", "PluginPassiveScanner", ")", "{", "if", "(", "(", "(", "PluginPassiveScanne...
Returns the PassiveScan rule with the given id @param pluginId @return the PassiveScan rule with the given id, or null if not found @since TODO add version
[ "Returns", "the", "PassiveScan", "rule", "with", "the", "given", "id" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/pscan/PassiveScannerList.java#L96-L105
129,488
zaproxy/zaproxy
src/org/zaproxy/zap/utils/ContentMatcher.java
ContentMatcher.getInstance
public static ContentMatcher getInstance(InputStream xmlInputStream) { ContentMatcher cm = new ContentMatcher(); // Load the pattern definitions from an XML file try { cm.loadXMLPatternDefinitions(xmlInputStream); } catch (JDOMException | IOException ex) ...
java
public static ContentMatcher getInstance(InputStream xmlInputStream) { ContentMatcher cm = new ContentMatcher(); // Load the pattern definitions from an XML file try { cm.loadXMLPatternDefinitions(xmlInputStream); } catch (JDOMException | IOException ex) ...
[ "public", "static", "ContentMatcher", "getInstance", "(", "InputStream", "xmlInputStream", ")", "{", "ContentMatcher", "cm", "=", "new", "ContentMatcher", "(", ")", ";", "// Load the pattern definitions from an XML file\r", "try", "{", "cm", ".", "loadXMLPatternDefinition...
Direct method for a complete ContentMatcher instance creation. @param xmlInputStream the stream of the XML file that need to be used for initialization @return a ContentMatcher instance
[ "Direct", "method", "for", "a", "complete", "ContentMatcher", "instance", "creation", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/utils/ContentMatcher.java#L75-L87
129,489
zaproxy/zaproxy
src/org/zaproxy/zap/utils/ContentMatcher.java
ContentMatcher.findInContent
public String findInContent(String content) { // First check for a simple exact occurrence for (BoyerMooreMatcher matcher : strings) { if (matcher.findInContent(content) >= 0) return matcher.getPattern(); } // Then check for a regex o...
java
public String findInContent(String content) { // First check for a simple exact occurrence for (BoyerMooreMatcher matcher : strings) { if (matcher.findInContent(content) >= 0) return matcher.getPattern(); } // Then check for a regex o...
[ "public", "String", "findInContent", "(", "String", "content", ")", "{", "// First check for a simple exact occurrence\r", "for", "(", "BoyerMooreMatcher", "matcher", ":", "strings", ")", "{", "if", "(", "matcher", ".", "findInContent", "(", "content", ")", ">=", ...
Search for an occurrence inside a specific content @param content the string content to search into @return the found occurrence or null if no match has been done
[ "Search", "for", "an", "occurrence", "inside", "a", "specific", "content" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/utils/ContentMatcher.java#L133-L152
129,490
zaproxy/zaproxy
src/org/zaproxy/zap/utils/ContentMatcher.java
ContentMatcher.findAllInContent
public List<String> findAllInContent(String content) { List<String> results = new LinkedList<String>(); // First check for all simple exact occurrences for (BoyerMooreMatcher matcher : strings) { if (matcher.findInContent(content) >= 0) result...
java
public List<String> findAllInContent(String content) { List<String> results = new LinkedList<String>(); // First check for all simple exact occurrences for (BoyerMooreMatcher matcher : strings) { if (matcher.findInContent(content) >= 0) result...
[ "public", "List", "<", "String", ">", "findAllInContent", "(", "String", "content", ")", "{", "List", "<", "String", ">", "results", "=", "new", "LinkedList", "<", "String", ">", "(", ")", ";", "// First check for all simple exact occurrences\r", "for", "(", "...
Search for all possible occurrences inside a specific content @param content the string content to search into @return a list of existing occurrences
[ "Search", "for", "all", "possible", "occurrences", "inside", "a", "specific", "content" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/utils/ContentMatcher.java#L159-L179
129,491
zaproxy/zaproxy
src/org/parosproxy/paros/network/HttpSender.java
HttpSender.sendAndReceive
public void sendAndReceive(HttpMessage msg, boolean isFollowRedirect) throws IOException { log.debug("sendAndReceive " + msg.getRequestHeader().getMethod() + " " + msg.getRequestHeader().getURI() + " start"); msg.setTimeSentMillis(System.currentTimeMillis()); try { notifyRequestListeners(msg); ...
java
public void sendAndReceive(HttpMessage msg, boolean isFollowRedirect) throws IOException { log.debug("sendAndReceive " + msg.getRequestHeader().getMethod() + " " + msg.getRequestHeader().getURI() + " start"); msg.setTimeSentMillis(System.currentTimeMillis()); try { notifyRequestListeners(msg); ...
[ "public", "void", "sendAndReceive", "(", "HttpMessage", "msg", ",", "boolean", "isFollowRedirect", ")", "throws", "IOException", "{", "log", ".", "debug", "(", "\"sendAndReceive \"", "+", "msg", ".", "getRequestHeader", "(", ")", ".", "getMethod", "(", ")", "+...
Send and receive a HttpMessage. @param msg @param isFollowRedirect @throws HttpException @throws IOException @see #sendAndReceive(HttpMessage, HttpRequestConfig)
[ "Send", "and", "receive", "a", "HttpMessage", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/network/HttpSender.java#L402-L450
129,492
zaproxy/zaproxy
src/org/parosproxy/paros/view/AbstractParamDialog.java
AbstractParamDialog.getJSplitPane
private AbstractParamContainerPanel getJSplitPane() { if (jSplitPane == null) { jSplitPane = new AbstractParamContainerPanel(); jSplitPane.setVisible(true); if (this.rootName != null) { jSplitPane.getRootNode().setUserObject(rootName); } } ...
java
private AbstractParamContainerPanel getJSplitPane() { if (jSplitPane == null) { jSplitPane = new AbstractParamContainerPanel(); jSplitPane.setVisible(true); if (this.rootName != null) { jSplitPane.getRootNode().setUserObject(rootName); } } ...
[ "private", "AbstractParamContainerPanel", "getJSplitPane", "(", ")", "{", "if", "(", "jSplitPane", "==", "null", ")", "{", "jSplitPane", "=", "new", "AbstractParamContainerPanel", "(", ")", ";", "jSplitPane", ".", "setVisible", "(", "true", ")", ";", "if", "("...
This method initializes jSplitPane @return javax.swing.JSplitPane
[ "This", "method", "initializes", "jSplitPane" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/view/AbstractParamDialog.java#L245-L255
129,493
zaproxy/zaproxy
src/org/zaproxy/zap/extension/api/ApiGeneratorUtils.java
ApiGeneratorUtils.getAllImplementors
public static List<ApiImplementor> getAllImplementors() { List<ApiImplementor> imps = new ArrayList<>(); ApiImplementor api; imps.add(new AlertAPI(null)); api = new AntiCsrfAPI(null); api.addApiOptions(new AntiCsrfParam()); imps.add(api); imps.add(new PassiveScanAPI(null)); imps.add(new SearchAP...
java
public static List<ApiImplementor> getAllImplementors() { List<ApiImplementor> imps = new ArrayList<>(); ApiImplementor api; imps.add(new AlertAPI(null)); api = new AntiCsrfAPI(null); api.addApiOptions(new AntiCsrfParam()); imps.add(api); imps.add(new PassiveScanAPI(null)); imps.add(new SearchAP...
[ "public", "static", "List", "<", "ApiImplementor", ">", "getAllImplementors", "(", ")", "{", "List", "<", "ApiImplementor", ">", "imps", "=", "new", "ArrayList", "<>", "(", ")", ";", "ApiImplementor", "api", ";", "imps", ".", "add", "(", "new", "AlertAPI",...
Return all of the available ApiImplementors. If you implement a new ApiImplementor then you must add it to this class. @return all of the available ApiImplementors.
[ "Return", "all", "of", "the", "available", "ApiImplementors", ".", "If", "you", "implement", "a", "new", "ApiImplementor", "then", "you", "must", "add", "it", "to", "this", "class", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/api/ApiGeneratorUtils.java#L59-L113
129,494
zaproxy/zaproxy
src/org/zaproxy/zap/extension/anticsrf/ExtensionAntiCSRF.java
ExtensionAntiCSRF.generateForm
public String generateForm(HttpMessage msg) throws UnsupportedEncodingException { String requestUri = msg.getRequestHeader().getURI().toString(); StringBuilder sb = new StringBuilder(300); sb.append("<html>\n"); sb.append("<body>\n"); sb.append("<h3>"); sb.append(requestUri); sb.append("</h3>"); sb.appe...
java
public String generateForm(HttpMessage msg) throws UnsupportedEncodingException { String requestUri = msg.getRequestHeader().getURI().toString(); StringBuilder sb = new StringBuilder(300); sb.append("<html>\n"); sb.append("<body>\n"); sb.append("<h3>"); sb.append(requestUri); sb.append("</h3>"); sb.appe...
[ "public", "String", "generateForm", "(", "HttpMessage", "msg", ")", "throws", "UnsupportedEncodingException", "{", "String", "requestUri", "=", "msg", ".", "getRequestHeader", "(", ")", ".", "getURI", "(", ")", ".", "toString", "(", ")", ";", "StringBuilder", ...
Generates a HTML form from the given message. @param msg the message used to generate the HTML form, must not be {@code null}. @return a string containing the HTML form, never {@code null}. @throws UnsupportedEncodingException if an error occurred while encoding the values of the form. @since 2.7.0
[ "Generates", "a", "HTML", "form", "from", "the", "given", "message", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/anticsrf/ExtensionAntiCSRF.java#L472-L507
129,495
zaproxy/zaproxy
src/org/zaproxy/zap/extension/httppanel/view/syntaxhighlight/lexers/WwwFormTokenMaker.java
WwwFormTokenMaker.zzScanError
private void zzScanError(int errorCode) { String message; try { message = ZZ_ERROR_MSG[errorCode]; } catch (ArrayIndexOutOfBoundsException e) { message = ZZ_ERROR_MSG[ZZ_UNKNOWN_ERROR]; } throw new Error(message); }
java
private void zzScanError(int errorCode) { String message; try { message = ZZ_ERROR_MSG[errorCode]; } catch (ArrayIndexOutOfBoundsException e) { message = ZZ_ERROR_MSG[ZZ_UNKNOWN_ERROR]; } throw new Error(message); }
[ "private", "void", "zzScanError", "(", "int", "errorCode", ")", "{", "String", "message", ";", "try", "{", "message", "=", "ZZ_ERROR_MSG", "[", "errorCode", "]", ";", "}", "catch", "(", "ArrayIndexOutOfBoundsException", "e", ")", "{", "message", "=", "ZZ_ERR...
Reports an error that occured while scanning. In a wellformed scanner (no or only correct usage of yypushback(int) and a match-all fallback rule) this method will only be called with things that "Can't Possibly Happen". If this method is called, something is seriously wrong (e.g. a JFlex bug producing a faulty scanner...
[ "Reports", "an", "error", "that", "occured", "while", "scanning", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/zaproxy/zap/extension/httppanel/view/syntaxhighlight/lexers/WwwFormTokenMaker.java#L447-L457
129,496
zaproxy/zaproxy
src/org/parosproxy/paros/extension/ExtensionLoader.java
ExtensionLoader.addProxyServer
public void addProxyServer(ProxyServer proxyServer) { proxyServers.add(proxyServer); extensionHooks.values().forEach(extHook -> hookProxyServer(extHook, proxyServer)); }
java
public void addProxyServer(ProxyServer proxyServer) { proxyServers.add(proxyServer); extensionHooks.values().forEach(extHook -> hookProxyServer(extHook, proxyServer)); }
[ "public", "void", "addProxyServer", "(", "ProxyServer", "proxyServer", ")", "{", "proxyServers", ".", "add", "(", "proxyServer", ")", ";", "extensionHooks", ".", "values", "(", ")", ".", "forEach", "(", "extHook", "->", "hookProxyServer", "(", "extHook", ",", ...
Adds the given proxy server, to be automatically updated with proxy related listeners. @param proxyServer the proxy server to add, must not be null. @since TODO add version @see #removeProxyServer(ProxyServer)
[ "Adds", "the", "given", "proxy", "server", "to", "be", "automatically", "updated", "with", "proxy", "related", "listeners", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/extension/ExtensionLoader.java#L260-L263
129,497
zaproxy/zaproxy
src/org/parosproxy/paros/extension/ExtensionLoader.java
ExtensionLoader.removeProxyServer
public void removeProxyServer(ProxyServer proxyServer) { proxyServers.remove(proxyServer); extensionHooks.values().forEach(extHook -> unhookProxyServer(extHook, proxyServer)); }
java
public void removeProxyServer(ProxyServer proxyServer) { proxyServers.remove(proxyServer); extensionHooks.values().forEach(extHook -> unhookProxyServer(extHook, proxyServer)); }
[ "public", "void", "removeProxyServer", "(", "ProxyServer", "proxyServer", ")", "{", "proxyServers", ".", "remove", "(", "proxyServer", ")", ";", "extensionHooks", ".", "values", "(", ")", ".", "forEach", "(", "extHook", "->", "unhookProxyServer", "(", "extHook",...
Removes the given proxy server. @param proxyServer the proxy server to remove, must not be null. @since TODO add version @see #addProxyServer(ProxyServer)
[ "Removes", "the", "given", "proxy", "server", "." ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/extension/ExtensionLoader.java#L293-L296
129,498
zaproxy/zaproxy
src/org/parosproxy/paros/extension/ExtensionLoader.java
ExtensionLoader.startLifeCycle
public void startLifeCycle(Extension ext) throws DatabaseException, DatabaseUnsupportedException { ext.init(); ext.databaseOpen(model.getDb()); ext.initModel(model); ext.initXML(model.getSession(), model.getOptionsParam()); ext.initView(view); ExtensionHoo...
java
public void startLifeCycle(Extension ext) throws DatabaseException, DatabaseUnsupportedException { ext.init(); ext.databaseOpen(model.getDb()); ext.initModel(model); ext.initXML(model.getSession(), model.getOptionsParam()); ext.initView(view); ExtensionHoo...
[ "public", "void", "startLifeCycle", "(", "Extension", "ext", ")", "throws", "DatabaseException", ",", "DatabaseUnsupportedException", "{", "ext", ".", "init", "(", ")", ";", "ext", ".", "databaseOpen", "(", "model", ".", "getDb", "(", ")", ")", ";", "ext", ...
Initialize a specific Extension @param ext the Extension that need to be initialized @throws DatabaseUnsupportedException @throws DatabaseException
[ "Initialize", "a", "specific", "Extension" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/extension/ExtensionLoader.java#L759-L799
129,499
zaproxy/zaproxy
src/org/parosproxy/paros/extension/ExtensionLoader.java
ExtensionLoader.hookCommandLineListener
public void hookCommandLineListener(CommandLine cmdLine) throws Exception { List<CommandLineArgument[]> allCommandLineList = new ArrayList<>(); Map<String, CommandLineListener> extMap = new HashMap<>(); for (Map.Entry<Extension, ExtensionHook> entry : extensionHooks.entrySet()) { ...
java
public void hookCommandLineListener(CommandLine cmdLine) throws Exception { List<CommandLineArgument[]> allCommandLineList = new ArrayList<>(); Map<String, CommandLineListener> extMap = new HashMap<>(); for (Map.Entry<Extension, ExtensionHook> entry : extensionHooks.entrySet()) { ...
[ "public", "void", "hookCommandLineListener", "(", "CommandLine", "cmdLine", ")", "throws", "Exception", "{", "List", "<", "CommandLineArgument", "[", "]", ">", "allCommandLineList", "=", "new", "ArrayList", "<>", "(", ")", ";", "Map", "<", "String", ",", "Comm...
Hook command line listener with the command line processor @param cmdLine @throws java.lang.Exception
[ "Hook", "command", "line", "listener", "with", "the", "command", "line", "processor" ]
0cbe5121f2ae1ecca222513d182759210c569bec
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/extension/ExtensionLoader.java#L942-L965