Skip to content

Commit

Permalink
automatic commit at releng box
Browse files Browse the repository at this point in the history
  • Loading branch information
mc36 committed Feb 8, 2025
1 parent 58da916 commit cd203f1
Show file tree
Hide file tree
Showing 8 changed files with 50 additions and 5 deletions.
3 changes: 2 additions & 1 deletion rtr-sw.txt
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,9 @@ aaa userlist access
forbidden ^show.*config$
forbidden ^show config.*$
allowed show .*
allowed display .*
allowed view .*
allowed watch .*
allowed display .*
allowed differs .*
allowed terminal .*
allowed test .*
Expand Down
7 changes: 7 additions & 0 deletions src/org/freertr/cfg/cfgAll.java
Original file line number Diff line number Diff line change
Expand Up @@ -826,6 +826,11 @@ public class cfgAll {
*/
public static String whoisOption = null;

/**
* whois file
*/
public static String whoisFile = null;

/**
* list of asn tools
*/
Expand Down Expand Up @@ -1394,6 +1399,7 @@ public class cfgAll {
"!" + cmds.negated + cmds.tabulator + "client whois-proxy",
"!" + cmds.negated + cmds.tabulator + "client whois-server",
"!" + cmds.negated + cmds.tabulator + "client whois-option",
"!" + cmds.negated + cmds.tabulator + "client whois-file",
"!" + cmds.negated + cmds.tabulator + "client config-server",
"!" + cmds.negated + cmds.tabulator + "client config-username",
"!" + cmds.negated + cmds.tabulator + "client config-password",
Expand Down Expand Up @@ -3789,6 +3795,7 @@ private static List<String> getGlobalRunEnd(int filter) {
cmds.cfgLine(l, !preferIpv6, "", "client prefer-ipv6", "");
cmds.cfgLine(l, whoisServer == null, "", "client whois-server", whoisServer);
cmds.cfgLine(l, whoisOption == null, "", "client whois-option", whoisOption);
cmds.cfgLine(l, whoisFile == null, "", "client whois-file", whoisFile);
if (whoisOnline != null) {
String a = "";
for (int i = 0; i < whoisOnline.size(); i++) {
Expand Down
24 changes: 24 additions & 0 deletions src/org/freertr/clnt/clntWhois.java
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,30 @@ public static userFormat showLocalCache() {
*/
public static void purgeLocalCache() {
asnameCache.clear();
if (cfgAll.whoisFile == null) {
return;
}
List<String> txt = bits.txt2buf(cfgAll.whoisFile);
if (txt == null) {
return;
}
for (int o = 0; o < txt.size(); o++) {
String a = txt.get(o);
int i = a.lastIndexOf(",");
if (i > 0) {
a = a.substring(0, i);
}
i = a.indexOf(" ");
int p = bits.str2num(a.substring(0, i));
a = a.substring(i + 1, a.length());
i = a.indexOf(" ");
if (i > 0) {
a = a.substring(0, i);
}
clntWhoisAsn ntry = new clntWhoisAsn(p);
ntry.name = a;
asnameCache.put(ntry);
}
}

private final clntProxy proxy;
Expand Down
13 changes: 13 additions & 0 deletions src/org/freertr/user/userConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@
import org.freertr.clnt.clntNetflow;
import org.freertr.clnt.clntNtp;
import org.freertr.clnt.clntSyslog;
import org.freertr.clnt.clntWhois;
import org.freertr.enc.encBase64;
import org.freertr.cry.cryCertificate;
import org.freertr.cry.cryKeyDSA;
Expand Down Expand Up @@ -564,6 +565,8 @@ private void getHelpGlobal(userHelping l) {
l.add(null, "3 . <str> server name");
l.add(null, "2 3 whois-option set whois option");
l.add(null, "3 . <str> server name");
l.add(null, "2 3 whois-file set whois file");
l.add(null, "3 . <str> server name");
l.add(null, "2 3 whois-proxy specify proxy profile");
l.add(null, "3 . <name:prx> name of profile");
l.add(null, "2 . password-stars type stars in passwords");
Expand Down Expand Up @@ -2654,6 +2657,11 @@ private void doCmdNoClient() {
cfgAll.whoisOption = null;
return;
}
if (s.equals("whois-file")) {
cfgAll.whoisFile = null;
clntWhois.purgeLocalCache();
return;
}
if (s.equals("whois-proxy")) {
cfgAll.whoisProxy = null;
return;
Expand Down Expand Up @@ -2906,6 +2914,11 @@ private void doCmdClient() {
cfgAll.whoisOption = cmd.getRemaining();
return;
}
if (a.equals("whois-file")) {
cfgAll.whoisFile = cmd.getRemaining();
clntWhois.purgeLocalCache();
return;
}
if (a.equals("whois-proxy")) {
cfgProxy prx = cfgAll.proxyFind(cmd.word(), false);
if (prx == null) {
Expand Down
2 changes: 1 addition & 1 deletion src/rtr.csv
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
url;file;result;test
-;-;-;freeRouter v25.2.8-cur, done by sprscc13@mrn0b0dy.
-;-;-;2025-02-08 10:07:57, took 00:15:30, with 50 workers, on 3634 cases, 0 failed, 0 traces, 2 retries
-;-;-;2025-02-08 10:57:18, took 00:15:52, with 50 workers, on 3634 cases, 0 failed, 0 traces, 3 retries
-;-;-;./rtr.bin, null
http://sources.freertr.org/cfg/basic01.tst;basic01.tst;success;dummy test
http://sources.freertr.org/cfg/basic02.tst;basic02.tst;success;interface with slot
Expand Down
2 changes: 1 addition & 1 deletion src/rtr.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</style>
<title>tester</title></head><body>
release: freeRouter v25.2.8-cur, done by sprscc13@mrn0b0dy.<br/>
tested: 2025-02-08 10:07:57, took 00:15:30, with 50 workers, on 3634 cases, 0 failed, 0 traces, 2 retries<br/>
tested: 2025-02-08 10:57:18, took 00:15:52, with 50 workers, on 3634 cases, 0 failed, 0 traces, 3 retries<br/>
jvm: ./rtr.bin, other: null<br/>
<br/>
<table><thead><tr><td><b>file</b></td><td><b>result</b></td><td><b>test</b></td></tr></thead><tbody>
Expand Down
2 changes: 1 addition & 1 deletion src/rtr8.csv
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
url;file;result;test
-;-;-;freeRouter v25.2.8-cur, done by sprscc13@mrn0b0dy.
-;-;-;2025-02-08 10:22:18, took 00:13:51, with 50 workers, on 700 cases, 0 failed, 0 traces, 0 retries
-;-;-;2025-02-08 11:10:01, took 00:12:12, with 50 workers, on 700 cases, 0 failed, 0 traces, 0 retries
-;-;-;./rtr.bin, udp
http://sources.freertr.org/cfg/p4lang-acl001.tst;p4lang-acl001.tst;success;p4lang: copp
http://sources.freertr.org/cfg/p4lang-acl002.tst;p4lang-acl002.tst;success;p4lang: ingress access list
Expand Down
2 changes: 1 addition & 1 deletion src/rtr8.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</style>
<title>tester</title></head><body>
release: freeRouter v25.2.8-cur, done by sprscc13@mrn0b0dy.<br/>
tested: 2025-02-08 10:22:18, took 00:13:51, with 50 workers, on 700 cases, 0 failed, 0 traces, 0 retries<br/>
tested: 2025-02-08 11:10:01, took 00:12:12, with 50 workers, on 700 cases, 0 failed, 0 traces, 0 retries<br/>
jvm: ./rtr.bin, other: udp<br/>
<br/>
<table><thead><tr><td><b>file</b></td><td><b>result</b></td><td><b>test</b></td></tr></thead><tbody>
Expand Down

0 comments on commit cd203f1

Please sign in to comment.