Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 691c7cf

Browse files
TmmmmmRthc202
authored andcommittedNov 20, 2024··
second batch of reviews
1 parent a43d479 commit 691c7cf

File tree

274 files changed

+91
-4446
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

274 files changed

+91
-4446
lines changed
 

‎addOns/llm/src/main/java/org/zaproxy/addon/llm/ExtensionLlm.java

+2-3
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,6 @@ public void hook(ExtensionHook extensionHook) {
7272
extensionHook.getHookMenu().addImportMenuItem(getMenuLLM());
7373
extensionHook.getHookMenu().addPopupMenuItem(getCheckLlmMenu());
7474
extensionHook.addOptionsParamSet(getOptionsParam());
75-
// change to a message
7675
getView().getOptionsDialog().addParamPanel(ROOT, getOptionsPanel(), true);
7776

7877
extensionHook.addSessionListener(
@@ -114,10 +113,10 @@ private ZapMenuItem getMenuLLM() {
114113
if (menuLLM == null) {
115114
menuLLM =
116115
new ZapMenuItem(
117-
"llm.topmenu.import.importSwagger",
116+
"llm.topmenu.import.importOpenAPI",
118117
getView().getMenuShortcutKeyStroke(KeyEvent.VK_J, 0, false));
119118
menuLLM.setToolTipText(
120-
Constant.messages.getString("llm.topmenu.import.importSwagger.tooltip"));
119+
Constant.messages.getString("llm.topmenu.import.importOpenAPI.tooltip"));
121120
menuLLM.addActionListener(
122121
e -> {
123122
if (importDialog == null) {

‎addOns/llm/src/main/java/org/zaproxy/addon/llm/services/LlmAssistant.java

+2-3
Original file line numberDiff line numberDiff line change
@@ -27,23 +27,22 @@
2727

2828
public interface LlmAssistant {
2929
@UserMessage(
30-
"Given the following swagger generate list of chained HTTP request to simulate a real world user : {{swagger}} ")
30+
"GGiven the following OpenAPI definition, generate a list of chained HTTP requests to simulate a real world user : {{swagger}} ")
3131
HttpRequestList extractHttpRequests(String swagger);
3232

3333
@UserMessage(
3434
"As software architect, and based on your previous answer, generate other potential missing endpoints that are not mentioned in the swagger file. For example, if there is GET /product/1, suggest DELETE /product/1 if it's not mentioned")
3535
HttpRequestList complete();
3636

3737
@SystemMessage(
38-
"You are a web application security expert in review false positives. Answer only in JSON.")
38+
"You are a web application security expert reviewing false positives. Answer only in JSON.")
3939
@UserMessage(
4040
"Your task is to review the following finding from ZAP (Zed Attack Proxy).\n"
4141
+ "The confidence level is a pull down field which allows you to specify how confident you are in the validity of the finding : \n"
4242
+ "- 0 if it's False Positive\n"
4343
+ "- 1 if it's Low\n"
4444
+ "- 2 if it's Medium\n"
4545
+ "- 3 if it's High\n"
46-
+ "- 4 if it's Confirmed\n"
4746
+ "\n"
4847
+ "The alert is described as follows : {{description}}\n"
4948
+ "\n"

0 commit comments

Comments
 (0)
Please sign in to comment.