mirror of https://github.com/sipwise/sems.git
There are cases when calls coming to a subscriber of C5 CE, is being challenged by this subscriber, the use case for that could be if for e.g. we have a PBX/SBC connected to NGCP via subscriber's object. Current implementation of SEMS works so, that in case parameters; 'enable_auth' and 'enable_aleg_auth' are set to value 'yes', SEMS tries to pass the digest for the calling party. This leads to the empty 'username' and wrong 'response' parameters of the Proxy-Authorization header, eventually the Authorization process is failed. This is to be changed, so in case 'u=', 'p=' and 'd=' have not been previously sent by the Proxy (in 'P-App-Param:'), or rather they are empty, authentication should be transparent, hence be processed by the calling side, with no interfer from SEMS into that. Change-Id: I9bced848d27f8c23bd557609277d5127e7e8696amr10.0.1
parent
50d482062c
commit
5ef025a2bf
@ -0,0 +1,13 @@
|
||||
--- a/core/plug-in/uac_auth/UACAuth.cpp
|
||||
+++ b/core/plug-in/uac_auth/UACAuth.cpp
|
||||
@@ -173,7 +173,9 @@ bool UACAuth::onSipReply(const AmSipRequ
|
||||
// credential->realm.c_str(),
|
||||
// credential->user.c_str(),
|
||||
// credential->pwd.c_str());
|
||||
- if (!nonce_reuse &&
|
||||
+ if ((credential->user.empty() || credential->pwd.empty()) && reply.code==407) {
|
||||
+ DBG("No credentials to pass the challenge from behalf of B2B, sending 407 transparently\n");
|
||||
+ } else if (!nonce_reuse &&
|
||||
(((reply.code == 401) &&
|
||||
getHeader(ri->second.hdrs, SIP_HDR_AUTHORIZATION, true).length()) ||
|
||||
((reply.code == 407) &&
|
||||
Loading…
Reference in new issue