Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP: generate databases #6

Merged
merged 3 commits into from
Jan 26, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions app/src/main/java/us/spotco/malwarescanner/Database.java
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,7 @@ public static void loadDatabase(Context context, boolean forceReload, Concurrent
signaturesMD5Extended = null;
domains = null;
File publicKey = new File(databasePath + "/gpg.key");

GPGDetachedSignatureVerifier verifier = new GPGDetachedSignatureVerifier(Utils.getSigningKey(context));
for (SignatureDatabase database : signatureDatabases) {
File databaseLocation = new File(databasePath + "/" + database.getName());
Expand Down
4 changes: 2 additions & 2 deletions app/src/main/java/us/spotco/malwarescanner/Utils.java
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,9 @@ class Utils {
private static Context context = null;
public final static int MAX_SCAN_SIZE = (1000 * 1000) * 500; //500MB
public final static int MAX_SCAN_SIZE_REALTIME = (1000 * 1000) * 250; //250MB
public final static String DATABASE_URL_DEFAULT = "https://divested.dev/MalwareScannerSignatures/";
public final static String DATABASE_URL_DEFAULT = "https://raw.githubusercontent.com/MaintainTeam/HypatiaDatabases/refs/heads/main/";
public final static String DATABASE_URL_CLOUDFLARE = "https://eeyo.re/MalwareScannerSignatures/";
public final static String SIGNING_KEY_DEFAULT = "BADFCABDDBF5B694";
public final static String SIGNING_KEY_DEFAULT = "5298C0C0C3E73288";

public static final AtomicInteger FILES_SCANNED = new AtomicInteger();
public final static ConcurrentHashMap<String, Long> MATCHED_FILES_TIME = new ConcurrentHashMap<>();
Expand Down
Loading