diff --git a/sipsak.1 b/sipsak.1 index 5368319..d65ba0e 100644 --- a/sipsak.1 +++ b/sipsak.1 @@ -175,6 +175,12 @@ or .B none will result in no contact header in the REGISTER request and thus the server should answer with the current bindings for the account at the registrar. +The special words +.B * +or +.B star +will result in Contact header containing just a star, e.g. to remove all +bindings by using expires value 0 together with this Contact. .IP "-d, --ignore-redirects" If this option is set all redirects will be ignored. By default without this diff --git a/sipsak.c b/sipsak.c index 49460c6..c370c49 100644 --- a/sipsak.c +++ b/sipsak.c @@ -393,7 +393,8 @@ int main(int argc, char *argv[]) (strlen(optarg) == 4 && STRNCASECMP(optarg, "none", 4) == 0)) { empty_contact = 1; } - else if (strlen(optarg) == 1 && STRNCASECMP(optarg, "*", 1) == 0) { + else if ((strlen(optarg) == 1 && STRNCASECMP(optarg, "*", 1) == 0) || + (strlen(optarg) == 4 && STRNCASECMP(optarg, "star", 4) == 0)) { contact_uri=str_alloc(strlen(optarg)+1); strncpy(contact_uri, optarg, strlen(optarg)); }