Class ShieldSignal
java.lang.Object
com.codename1.security.shield.ShieldSignal
One runtime self-protection observation, such as "a hooking framework is loaded".
Signals are reports, not verdicts. The device never decides it is compromised and never terminates itself over one of these; it reports what it saw and the attestation service decides whether to keep issuing tokens. That ordering matters for two reasons: a hard local exit is trivially patched out of the binary, and it destroys the telemetry that would have told the developer an attack was happening at all.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringAn accessibility service that is not on the allow list is enabled.static final StringA debugger is attached to the process.static final StringThe app is running on an emulator or simulator.static final StringA dynamic instrumentation or hooking framework is present.static final StringA jailbroken iOS device.static final StringThe app's signing certificate does not match the one it was built with.static final StringA rooted Android device. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionWhat was actually observed, for example the offending package or library name.getId()A stable identifier such asHOOK.intHow strongly this points at an attack, 0 to 100.longWhen the observation was made.toString()Returns a string representation of the object.
-
Field Details
-
ROOT
-
JAILBREAK
-
HOOK
A dynamic instrumentation or hooking framework is present.- See Also:
-
EMULATOR
-
DEBUGGER
-
REPACKAGED
The app's signing certificate does not match the one it was built with.- See Also:
-
ACCESSIBILITY
An accessibility service that is not on the allow list is enabled.- See Also:
-
-
Constructor Details
-
ShieldSignal
-
-
Method Details
-
getId
-
getSeverity
public int getSeverity()How strongly this points at an attack, 0 to 100. Advisory only -- the service applies the policy, so a low severity here does not mean the service will ignore it. -
getDetail
What was actually observed, for example the offending package or library name. May be null. -
getTimestamp
public long getTimestamp()When the observation was made. -
toString
Description copied from class:ObjectReturns a string representation of the object. In general, the toString method returns a string that "textually represents" this object. The result should be a concise but informative representation that is easy for a person to read. It is recommended that all subclasses override this method. The toString method for class Object returns a string consisting of the name of the class of which the object is an instance, the at-sign character `@', and the unsigned hexadecimal representation of the hash code of the object. In other words, this method returns a string equal to the value of: getClass().getName() + '@' + Integer.toHexString(hashCode())
-