Class BurpRuntimeMetadata
java.lang.Object
ai.attackframework.tools.burp.utils.BurpRuntimeMetadata
Caches stable Burp metadata used by async exporters.
Background reporters should prefer this helper over probing Burp sub-APIs on every
export cycle. That avoids repeated lifecycle-sensitive calls during extension startup,
shutdown, or project transitions, while still allowing the cache to be primed from a known
good MontoyaApi instance.
-
Method Summary
Modifier and TypeMethodDescriptionstatic StringReturns the cached Burp version, resolving it lazily when needed.static voidclear()Clears all cached metadata.static voidprime(burp.api.montoya.MontoyaApi api) Primes cached metadata from the provided API when values are not already known.static StringReturns the cached Burp project id, resolving it lazily when needed.
-
Method Details
-
prime
public static void prime(burp.api.montoya.MontoyaApi api) Primes cached metadata from the provided API when values are not already known.Safe to call multiple times. Failures are swallowed because callers use this helper to avoid turning lifecycle races into user-visible errors.
- Parameters:
api- current Montoya API handle; ignored whennull
-
burpVersion
Returns the cached Burp version, resolving it lazily when needed.When the value cannot be resolved safely, returns
null.- Returns:
- Burp version string, or
nullwhen unavailable
-
projectId
Returns the cached Burp project id, resolving it lazily when needed.When the value cannot be resolved safely, returns
null.- Returns:
- Burp project id, or
nullwhen unavailable
-
clear
public static void clear()Clears all cached metadata.
-