mirror of
https://github.com/google/santa.git
synced 2026-04-24 03:00:12 -04:00
This adds a full functional test for starting up an SNTApplication (with as few mocks as possible) and executing it with a directly recorded & collected EndpointSecurity event. This also fixes a potential race condition and segfault on Santa startup: due to es_subscribe being called first, it's possible for an es event to arrive before listenForDecisionRequests or listenForLogRequests are called, causing the SNTEndpointSecurityManager callbacks to call a nil pointer.
9 lines
191 B
C
9 lines
191 B
C
#include <stdio.h>
|
|
|
|
int main(int argc, char* argv[]) {
|
|
const char* evil =
|
|
"X5O!P%@AP[4\\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*";
|
|
printf("%s", evil);
|
|
return 0;
|
|
}
|