mirror of
https://github.com/richonguzman/LoRa_APRS_iGate.git
synced 2026-03-28 16:52:33 +01:00
loadCallsignList update
This commit is contained in:
@@ -667,7 +667,7 @@
|
||||
</svg>
|
||||
Black List
|
||||
</h5>
|
||||
<small>Add Callsigns with space between them to Blacklist them (* wild card allowed)</small>
|
||||
<small>Add Callsigns with space between them to Blacklist (* wildcard allowed)</small>
|
||||
</div>
|
||||
<div class="col-9">
|
||||
<div class="row">
|
||||
|
||||
@@ -67,7 +67,7 @@ ___________________________________________________________________*/
|
||||
#endif
|
||||
|
||||
|
||||
String versionDate = "2025-11-08";
|
||||
String versionDate = "2025-11-29";
|
||||
String versionNumber = "3.1.4.1";
|
||||
Configuration Config;
|
||||
WiFiClient aprsIsClient;
|
||||
|
||||
@@ -204,7 +204,7 @@ namespace LoRa_Utils {
|
||||
if (packet != "") {
|
||||
|
||||
String sender = packet.substring(3, packet.indexOf(">"));
|
||||
if (packet.substring(0,3) == "\x3c\xff\x01" && !STATION_Utils::isBlacklisted(sender)){ // avoid processing BlackListed stations
|
||||
if (packet.substring(0,3) == "\x3c\xff\x01" && !STATION_Utils::isBlacklisted(sender)) { // avoid processing BlackListed stations
|
||||
rssi = radio.getRSSI();
|
||||
snr = radio.getSNR();
|
||||
freqError = radio.getFrequencyError();
|
||||
|
||||
@@ -57,7 +57,7 @@ bool packetIsBeacon = false;
|
||||
|
||||
namespace STATION_Utils {
|
||||
|
||||
std::vector<String> loadCallSignList(const String& list) {
|
||||
std::vector<String> loadCallsignList(const String& list) {
|
||||
std::vector<String> loadedList;
|
||||
|
||||
String callsigns = list;
|
||||
@@ -77,12 +77,12 @@ namespace STATION_Utils {
|
||||
}
|
||||
|
||||
void loadBlacklistAndManagers() {
|
||||
blacklist = loadCallSignList(Config.blacklist);
|
||||
managers = loadCallSignList(Config.remoteManagement.managers);
|
||||
blacklist = loadCallsignList(Config.blacklist);
|
||||
managers = loadCallsignList(Config.remoteManagement.managers);
|
||||
}
|
||||
|
||||
bool checkCallsignList(const std::vector<String>& list, const String& callsign) {
|
||||
for (int i = 0; i < list.size(); i++) {
|
||||
for (size_t i = 0; i < list.size(); i++) {
|
||||
int wildcardIndex = list[i].indexOf("*");
|
||||
if (wildcardIndex >= 0) {
|
||||
String wildcard = list[i].substring(0, wildcardIndex);
|
||||
|
||||
Reference in New Issue
Block a user