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

Function ospCheckHeader

modules/osp/term_transaction.c:50–63  ·  view source on GitHub ↗

* Get OSP token * param msg SIP message * param ignore1 * param ignore2 * return MODULE_RETURNCODE_TRUE success, MODULE_RETURNCODE_FALSE failure */

Source from the content-addressed store, hash-verified

48 * return MODULE_RETURNCODE_TRUE success, MODULE_RETURNCODE_FALSE failure
49 */
50int ospCheckHeader(
51 struct sip_msg* msg,
52 char* ignore1,
53 char* ignore2)
54{
55 unsigned char buffer[OSP_TOKENBUF_SIZE];
56 unsigned int bufsize = sizeof(buffer);
57
58 if (ospGetOspToken(msg, buffer, &bufsize) != 0) {
59 return MODULE_RETURNCODE_FALSE;
60 } else {
61 return MODULE_RETURNCODE_TRUE;
62 }
63}
64
65/*
66 * Validate OSP token

Callers

nothing calls this directly

Calls 1

ospGetOspTokenFunction · 0.85

Tested by

no test coverage detected