DataDog / dd-native-appsec-js

Node.js bindings for libddwaf
Apache License 2.0
1 stars 3 forks source link

Crash in worker threads #82

Closed simon-id closed 10 months ago

simon-id commented 1 year ago
FATAL ERROR: v8::HandleScope::CreateHandle() Cannot create a handle without a HandleScope
 1: 0xb675b4 node::Abort() [/usr/local/bin/node]
 2: 0xa8aea0 node::FatalError(char const*, char const*) [/usr/local/bin/node]
 3: 0xd3a890 v8::Utils::ReportApiFailure(char const*, char const*) [/usr/local/bin/node]
 4: 0xec4774 v8::internal::HandleScope::Extend(v8::internal::Isolate*) [/usr/local/bin/node]
 5: 0xd3bf68 v8::EscapableHandleScope::EscapableHandleScope(v8::Isolate*) [/usr/local/bin/node]
 6: 0xb1ab88 napi_open_escapable_handle_scope [/usr/local/bin/node]
 7: 0xffff8c20d3b4 Napi::EscapableHandleScope::EscapableHandleScope(Napi::Env) [/web-ui/.yarn/unplugged/@datadog-native-appsec-npm-3.1.0-614b03cb6d/node_modules/@datadog/native-appsec/prebuilds/linux-arm64/node-napi.node]
 8: 0xffff8c2128e4 DDWAF::createContext(Napi::CallbackInfo const&) [/web-ui/.yarn/unplugged/@datadog-native-appsec-npm-3.1.0-614b03cb6d/node_modules/@datadog/native-appsec/prebuilds/linux-arm64/node-napi.node]
 9: 0xffff8c212f88  [/web-ui/.yarn/unplugged/@datadog-native-appsec-npm-3.1.0-614b03cb6d/node_modules/@datadog/native-appsec/prebuilds/linux-arm64/node-napi.node]
10: 0xb128e8  [/usr/local/bin/node]
11: 0xda1558  [/usr/local/bin/node]
12: 0xda2680 v8::internal::Builtin_HandleApiCall(int, unsigned long*, v8::internal::Isolate*) [/usr/local/bin/node]
13: 0x16760cc  [/usr/local/bin/node]

Profiling fixed it with: https://github.com/DataDog/pprof-nodejs/pull/92/files

simon-id commented 10 months ago

Fixed by #79 and released in v7.0.0