[SR-Users] sanity from uri check

Juha Heinanen jh at tutpro.com
Wed Mar 16 14:47:43 CET 2022


Daniel-Constantin Mierla writes:

> I pushed another commit. I tested a few cases:

Which commit was it?  I just built latest master and these were the new
commits that git pull found:

pdating d4af130477..dad4431726
Fast-forward
 src/core/resolve.c                   | 2 +-
 src/core/socket_info.c               | 1 +
 src/modules/db_berkeley/km_bdb_val.c | 8 ++++----
 src/modules/db_redis/redis_dbase.c   | 2 +-
 src/modules/db_text/doc/db_text.cfg  | 2 +-

Then I run the test and it did not fail:

INFO: OPTIONS <sip:test at test.tutpro.com> from <sip:@192.168.255.95:5062> is OK

Are you using the same config?

modparam("sanity", "default_checks", 1024)
modparam("sanity", "uri_checks", 3)  /* RURI, From */
modparam("sanity", "autodrop", 0)

    if (!sanity_check()) {
      xnotice("Request from <$var(src_ip)> has invalid syntax\n");
      exit;
    } else {
        xinfo("$rm <$ru> from <$fu> is OK\n");
    };

-- Juha



More information about the sr-users mailing list