Skip to content

Commit

Permalink
chore: pass certificate config through
Browse files Browse the repository at this point in the history
  • Loading branch information
achingbrain committed Jun 7, 2024
1 parent d1280c7 commit 2e41beb
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/peer-connection-wrapper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,17 @@ PeerConnectionWrapper::PeerConnectionWrapper(const Napi::CallbackInfo &info) : N
rtcConfig.disableFingerprintVerification = config.Get("disableFingerprintVerification").As<Napi::Boolean>();
}

// Specify certificate to use if set
if (config.Get("certificatePemFile").IsString()) {
rtcConfig.certificatePemFile = config.Get("certificatePemFile").As<Napi::String>().ToString();
}
if (config.Get("keyPemFile").IsString()) {
rtcConfig.keyPemFile = config.Get("keyPemFile").As<Napi::String>().ToString();
}
if (config.Get("keyPemPass").IsString()) {
rtcConfig.keyPemPass = config.Get("keyPemPass").As<Napi::String>().ToString();
}

// Create peer-connection
try
{
Expand Down

0 comments on commit 2e41beb

Please sign in to comment.