Skip to content

Commit 8b13ca6

Browse files
author
isayan
committed
upgrade depend library
1 parent 0332491 commit 8b13ca6

File tree

11 files changed

+71
-39
lines changed

11 files changed

+71
-39
lines changed

build.gradle

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ plugins {
1010
id 'java-library'
1111
id 'application'
1212
id 'com.github.johnrengelman.shadow' version '7.1.2'
13-
id 'org.asciidoctor.jvm.base' version '4.0.3'
14-
id 'org.asciidoctor.jvm.convert' version '4.0.3'
15-
id 'org.asciidoctor.jvm.pdf' version '4.0.3'
13+
id 'org.asciidoctor.jvm.base' version '4.0.4'
14+
id 'org.asciidoctor.jvm.convert' version '4.0.4'
15+
id 'org.asciidoctor.jvm.pdf' version '4.0.4'
1616
}
1717

1818
repositories {
@@ -103,7 +103,7 @@ dependencies {
103103
// https://mvnrepository.com/artifact/net.portswigger.burp.extensions/montoya-api
104104
implementation 'net.portswigger.burp.extensions:montoya-api:2024.12'
105105
// https://mvnrepository.com/artifact/commons-codec/commons-codec
106-
implementation 'commons-codec:commons-codec:1.17.1'
106+
implementation 'commons-codec:commons-codec:1.17.2'
107107
// https://mvnrepository.com/artifact/com.fifesoft/rsyntaxtextarea
108108
implementation 'com.fifesoft:rsyntaxtextarea:3.3.4'
109109

@@ -119,8 +119,8 @@ dependencies {
119119

120120
// Use JUnit Jupiter for testing.
121121
// https://mvnrepository.com/artifact/org.junit.jupiter/junit-jupiter-api
122-
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.9.3'
123-
testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.9.3'
122+
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.10.5'
123+
testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.10.5'
124124

125125
// testImplementation fileTree(dir: 'libs', include: ['*.jar'])
126126

@@ -132,7 +132,7 @@ dependencies {
132132
// https://mvnrepository.com/artifact/io.github.rburgst/okhttp-digest
133133
testImplementation 'io.github.rburgst:okhttp-digest:3.1.1'
134134
// https://mvnrepository.com/artifact/com.squareup.okhttp3/mockwebserver
135-
testImplementation 'com.squareup.okhttp3:mockwebserver:4.11.0'
135+
testImplementation 'com.squareup.okhttp3:mockwebserver:4.12.0'
136136

137137
// https://mvnrepository.com/artifact/org.mockito/mockito-core
138138
testImplementation 'org.mockito:mockito-core:5.4.0'
0 Bytes
Binary file not shown.

release/YaguraExtension-v3.2.jar

6.86 MB
Binary file not shown.

src/main/java/yagura/model/SendToExtend.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -225,13 +225,14 @@ public boolean isEnabled() {
225225
|| (this.contextMenu.invocationType() == null); // Orgnaizerではnull
226226
break;
227227
}
228-
case REQUEST_BODY_TO_FILE:
228+
case REQUEST_BODY_TO_FILE: {
229229
enabled = (this.contextMenu.invocationType() == InvocationType.PROXY_HISTORY)
230230
|| (this.contextMenu.invocationType() == InvocationType.SEARCH_RESULTS)
231231
|| (this.contextMenu.invocationType() == InvocationType.MESSAGE_EDITOR_REQUEST)
232232
|| (this.contextMenu.invocationType() == InvocationType.MESSAGE_VIEWER_REQUEST)
233233
|| (this.contextMenu.invocationType() == null); // Orgnaizerではnull
234234
break;
235+
}
235236
case RESPONSE_BODY_TO_FILE: {
236237
enabled = (this.contextMenu.invocationType() == InvocationType.PROXY_HISTORY)
237238
|| (this.contextMenu.invocationType() == InvocationType.SEARCH_RESULTS)
@@ -252,7 +253,7 @@ public boolean isEnabled() {
252253
|| (this.contextMenu.invocationType() == null); // Orgnaizerではnull
253254
break;
254255
}
255-
case MESSAGE_INFO_COPY:
256+
case MESSAGE_INFO_COPY: {
256257
enabled = (this.contextMenu.invocationType() == InvocationType.PROXY_HISTORY)
257258
|| (this.contextMenu.invocationType() == InvocationType.SEARCH_RESULTS)
258259
|| (this.contextMenu.invocationType() == InvocationType.MESSAGE_VIEWER_REQUEST)
@@ -261,6 +262,7 @@ public boolean isEnabled() {
261262
|| (this.contextMenu.invocationType() == InvocationType.MESSAGE_EDITOR_RESPONSE)
262263
|| (this.contextMenu.invocationType() == null); // Orgnaizerではnull
263264
break;
265+
}
264266
case ADD_HOST_TO_INCLUDE_SCOPE:
265267
case ADD_HOST_TO_EXCLUDE_SCOPE:
266268
case ADD_TO_EXCLUDE_SCOPE: {

src/main/java/yagura/model/SendToParameterProperty.java

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -242,10 +242,11 @@ public Properties getProperties() {
242242
public static String getParameter(SendToParameterProperty.SendToParameterType type, HttpRequestResponse messageInfo) {
243243
String value = null;
244244
switch (type) {
245-
case HISTORY_COMMENT:
245+
case HISTORY_COMMENT: {
246246
value = messageInfo.annotations().notes();
247247
break;
248-
case RESPONSE_TITLE:
248+
}
249+
case RESPONSE_TITLE: {
249250
if (messageInfo.response() != null) {
250251
try {
251252
HttpResponseWapper wrapResponse = new HttpResponseWapper(messageInfo.response());
@@ -262,8 +263,10 @@ public static String getParameter(SendToParameterProperty.SendToParameterType ty
262263
}
263264
}
264265
break;
265-
case HISTORY_NUMBER:
266+
}
267+
case HISTORY_NUMBER: {
266268
break;
269+
}
267270
}
268271
return value;
269272
}
@@ -275,14 +278,17 @@ public static String extractLinePart(SendToParameterProperty.LinePartType commen
275278
Matcher m = LINE_PART.matcher(part);
276279
if (m.find()) {
277280
switch (commentLineType) {
278-
case FIRST_LINE:
281+
case FIRST_LINE: {
279282
part = m.group(1);
280283
break;
281-
case SECOND_LINE:
284+
}
285+
case SECOND_LINE: {
282286
part = m.group(2);
283287
break;
284-
default:
288+
}
289+
default: {
285290
break;
291+
}
286292
}
287293
}
288294
return part;

src/main/java/yagura/model/SendToServer.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -492,12 +492,14 @@ public void run() {
492492
String authorizationPasswd = extendConnectionProp.getAuthorizationPasswd();
493493
okhttp3.Authenticator authenticator = null;
494494
switch (authorizationType) {
495-
case BASIC:
495+
case BASIC: {
496496
authenticator = new BasicAuthenticator(new com.burgstaller.okhttp.digest.Credentials(authorizationUser, authorizationPasswd));
497497
break;
498-
case DIGEST:
498+
}
499+
case DIGEST: {
499500
authenticator = new DigestAuthenticator(new com.burgstaller.okhttp.digest.Credentials(authorizationUser, authorizationPasswd));
500501
break;
502+
}
501503
}
502504

503505
// Proxy

src/main/java/yagura/view/BurpToolBar.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -416,14 +416,16 @@ private void mnuSaveProjectSettingsActionPerformed(java.awt.event.ActionEvent ev
416416

417417
public void applyStyleTheme(Theme theme) {
418418
switch (theme) {
419-
case DARK:
419+
case DARK: {
420420
this.tglIntercept.setIcon(inspector_off_dark);
421421
this.tglIntercept.setSelectedIcon(inspector_on_dark);
422422
break;
423-
case LIGHT:
423+
}
424+
case LIGHT: {
424425
this.tglIntercept.setIcon(inspector_off_light);
425426
this.tglIntercept.setSelectedIcon(inspector_on_light);
426427
break;
428+
}
427429
}
428430
this.tglIntercept.updateUI();
429431
}

src/main/java/yagura/view/ConnectionsPanel.java

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -569,15 +569,18 @@ public void setProperty(HttpExtendProperty prop) {
569569
this.rdoBurpClient.setSelected(true);
570570
}
571571
switch (httpProtocol) {
572-
case HTTP_1_1:
572+
case HTTP_1_1: {
573573
this.rdoHttpProtocol1.setSelected(true);
574574
break;
575-
case HTTP_2:
575+
}
576+
case HTTP_2: {
576577
this.rdoHttpProtocol2.setSelected(true);
577578
break;
578-
default:
579+
}
580+
default: {
579581
this.rdoHttpProtocolAuto.setSelected(true);
580582
break;
583+
}
581584
}
582585

583586
this.spnTimeout.setValue(prop.getTimeout());

src/main/java/yagura/view/HotKeyDlg.form

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
<AuxValue name="FormSettings_listenerGenerationStyle" type="java.lang.Integer" value="0"/>
1919
<AuxValue name="FormSettings_variablesLocal" type="java.lang.Boolean" value="false"/>
2020
<AuxValue name="FormSettings_variablesModifier" type="java.lang.Integer" value="2"/>
21-
<AuxValue name="designerSize" type="java.awt.Dimension" value="-84,-19,0,5,115,114,0,18,106,97,118,97,46,97,119,116,46,68,105,109,101,110,115,105,111,110,65,-114,-39,-41,-84,95,68,20,2,0,2,73,0,6,104,101,105,103,104,116,73,0,5,119,105,100,116,104,120,112,0,0,0,-65,0,0,1,-112"/>
21+
<AuxValue name="designerSize" type="java.awt.Dimension" value="-84,-19,0,5,115,114,0,18,106,97,118,97,46,97,119,116,46,68,105,109,101,110,115,105,111,110,65,-114,-39,-41,-84,95,68,20,2,0,2,73,0,6,104,101,105,103,104,116,73,0,5,119,105,100,116,104,120,112,0,0,0,-52,0,0,2,38"/>
2222
</AuxValues>
2323

2424
<Layout class="org.netbeans.modules.form.compat2.layouts.DesignBorderLayout"/>
@@ -33,19 +33,19 @@
3333
<Layout>
3434
<DimensionLayout dim="0">
3535
<Group type="103" groupAlignment="0" attributes="0">
36-
<Group type="102" attributes="0">
36+
<Group type="102" alignment="0" attributes="0">
3737
<EmptySpace max="-2" attributes="0"/>
3838
<Group type="103" groupAlignment="0" attributes="0">
39-
<Group type="102" alignment="0" attributes="0">
39+
<Component id="txtKey" min="-2" pref="250" max="-2" attributes="0"/>
40+
<Group type="102" attributes="0">
4041
<Component id="chkControl" min="-2" max="-2" attributes="0"/>
4142
<EmptySpace max="-2" attributes="0"/>
4243
<Component id="chkShift" min="-2" max="-2" attributes="0"/>
4344
<EmptySpace max="-2" attributes="0"/>
4445
<Component id="chkAlt" min="-2" max="-2" attributes="0"/>
4546
</Group>
46-
<Component id="txtKey" alignment="0" min="-2" pref="159" max="-2" attributes="0"/>
4747
</Group>
48-
<EmptySpace pref="235" max="32767" attributes="0"/>
48+
<EmptySpace pref="294" max="32767" attributes="0"/>
4949
</Group>
5050
</Group>
5151
</DimensionLayout>
@@ -60,7 +60,7 @@
6060
</Group>
6161
<EmptySpace max="-2" attributes="0"/>
6262
<Component id="txtKey" min="-2" max="-2" attributes="0"/>
63-
<EmptySpace pref="87" max="32767" attributes="0"/>
63+
<EmptySpace pref="100" max="32767" attributes="0"/>
6464
</Group>
6565
</Group>
6666
</DimensionLayout>
@@ -101,7 +101,7 @@
101101
<DimensionLayout dim="0">
102102
<Group type="103" groupAlignment="0" attributes="0">
103103
<Group type="102" alignment="1" attributes="0">
104-
<EmptySpace pref="203" max="32767" attributes="0"/>
104+
<EmptySpace pref="353" max="32767" attributes="0"/>
105105
<Component id="btnOK" min="-2" pref="84" max="-2" attributes="1"/>
106106
<EmptySpace type="unrelated" max="-2" attributes="0"/>
107107
<Component id="btnCancel" min="-2" pref="95" max="-2" attributes="1"/>

src/main/java/yagura/view/HotKeyDlg.java

Lines changed: 21 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -53,14 +53,14 @@ private void initComponents() {
5353
.addGroup(pnlMainLayout.createSequentialGroup()
5454
.addContainerGap()
5555
.addGroup(pnlMainLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
56+
.addComponent(txtKey, javax.swing.GroupLayout.PREFERRED_SIZE, 250, javax.swing.GroupLayout.PREFERRED_SIZE)
5657
.addGroup(pnlMainLayout.createSequentialGroup()
5758
.addComponent(chkControl)
5859
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
5960
.addComponent(chkShift)
6061
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
61-
.addComponent(chkAlt))
62-
.addComponent(txtKey, javax.swing.GroupLayout.PREFERRED_SIZE, 159, javax.swing.GroupLayout.PREFERRED_SIZE))
63-
.addContainerGap(235, Short.MAX_VALUE))
62+
.addComponent(chkAlt)))
63+
.addContainerGap(294, Short.MAX_VALUE))
6464
);
6565
pnlMainLayout.setVerticalGroup(
6666
pnlMainLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
@@ -72,7 +72,7 @@ private void initComponents() {
7272
.addComponent(chkAlt))
7373
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
7474
.addComponent(txtKey, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
75-
.addContainerGap(87, Short.MAX_VALUE))
75+
.addContainerGap(100, Short.MAX_VALUE))
7676
);
7777

7878
getContentPane().add(pnlMain, java.awt.BorderLayout.CENTER);
@@ -98,7 +98,7 @@ public void actionPerformed(java.awt.event.ActionEvent evt) {
9898
pnlApplyLayout.setHorizontalGroup(
9999
pnlApplyLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
100100
.addGroup(javax.swing.GroupLayout.Alignment.TRAILING, pnlApplyLayout.createSequentialGroup()
101-
.addContainerGap(203, Short.MAX_VALUE)
101+
.addContainerGap(353, Short.MAX_VALUE)
102102
.addComponent(btnOK, javax.swing.GroupLayout.PREFERRED_SIZE, 84, javax.swing.GroupLayout.PREFERRED_SIZE)
103103
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
104104
.addComponent(btnCancel, javax.swing.GroupLayout.PREFERRED_SIZE, 95, javax.swing.GroupLayout.PREFERRED_SIZE)
@@ -182,6 +182,20 @@ public void windowClosing(java.awt.event.WindowEvent e) {
182182
private javax.swing.JTextField txtKey;
183183
// End of variables declaration//GEN-END:variables
184184

185+
public void setHotKey(KeyStroke ks) {
186+
int modifiers = ks.getModifiers();
187+
if ((modifiers &= KeyEvent.CTRL_DOWN_MASK) == KeyEvent.CTRL_DOWN_MASK) {
188+
this.chkControl.setSelected(true);
189+
}
190+
if ((modifiers &= KeyEvent.SHIFT_DOWN_MASK) == KeyEvent.SHIFT_DOWN_MASK) {
191+
this.chkShift.setSelected(true);
192+
}
193+
if ((modifiers &= KeyEvent.ALT_GRAPH_DOWN_MASK) == KeyEvent.ALT_GRAPH_DOWN_MASK) {
194+
this.chkAlt.setSelected(true);
195+
}
196+
this.txtKey.setText(String.valueOf(ks.getKeyChar()));
197+
}
198+
185199
public KeyStroke getHotKey() {
186200
int modifiers = 0;
187201
if (this.chkControl.isSelected()) {
@@ -192,9 +206,9 @@ public KeyStroke getHotKey() {
192206
}
193207
if (this.chkAlt.isSelected()) {
194208
modifiers |= KeyEvent.ALT_GRAPH_DOWN_MASK;
195-
}
209+
}
196210
return KeyStroke.getKeyStroke(ConvertUtil.parseIntDefault(this.txtKey.getText(), -1), modifiers);
197-
}
211+
}
198212

199213

200214
}

0 commit comments

Comments
 (0)