MCPcopy Create free account
hub / github.com/OpenSIPS/opensips / cred_user

Function cred_user

pvar.c:1895–1907  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1893
1894
1895static inline str *cred_user(struct sip_msg *rq)
1896{
1897 struct hdr_field* h;
1898 auth_body_t* cred;
1899
1900 get_authorized_cred(rq->proxy_auth, &h);
1901 if (!h) get_authorized_cred(rq->authorization, &h);
1902 if (!h) return 0;
1903 cred=(auth_body_t*)(h->parsed);
1904 if (!cred || !cred->digest.username.user.len)
1905 return 0;
1906 return &cred->digest.username.user;
1907}
1908
1909
1910static inline str *cred_realm(struct sip_msg *rq)

Callers 1

pv_get_acc_usernameFunction · 0.85

Calls 1

get_authorized_credFunction · 0.85

Tested by

no test coverage detected