cipso_ipv4.c (3dcbbcda7c5b77c400791b26facd6593c5b176e0) cipso_ipv4.c (95d4e6be25a68cd9fbe8c0d356b585504d8db1c7)
1/*
2 * CIPSO - Commercial IP Security Option
3 *
4 * This is an implementation of the CIPSO 2.2 protocol as specified in
5 * draft-ietf-cipso-ipsecurity-01.txt with additional tag types as found in
6 * FIPS-188, copies of both documents can be found in the Documentation
7 * directory. While CIPSO never became a full IETF RFC standard many vendors
8 * have chosen to adopt the protocol and over the years it has become a

--- 471 unchanged lines hidden (view full) ---

480 * Description:
481 * Removes a DOI definition from the CIPSO engine, @callback is called to
482 * free any memory. The NetLabel routines will be called to release their own
483 * LSM domain mappings as well as our own domain list. Returns zero on
484 * success and negative values on failure.
485 *
486 */
487int cipso_v4_doi_remove(u32 doi,
1/*
2 * CIPSO - Commercial IP Security Option
3 *
4 * This is an implementation of the CIPSO 2.2 protocol as specified in
5 * draft-ietf-cipso-ipsecurity-01.txt with additional tag types as found in
6 * FIPS-188, copies of both documents can be found in the Documentation
7 * directory. While CIPSO never became a full IETF RFC standard many vendors
8 * have chosen to adopt the protocol and over the years it has become a

--- 471 unchanged lines hidden (view full) ---

480 * Description:
481 * Removes a DOI definition from the CIPSO engine, @callback is called to
482 * free any memory. The NetLabel routines will be called to release their own
483 * LSM domain mappings as well as our own domain list. Returns zero on
484 * success and negative values on failure.
485 *
486 */
487int cipso_v4_doi_remove(u32 doi,
488 u32 audit_secid,
488 struct netlbl_audit *audit_info,
489 void (*callback) (struct rcu_head * head))
490{
491 struct cipso_v4_doi *doi_def;
492 struct cipso_v4_domhsh_entry *dom_iter;
493
494 rcu_read_lock();
495 if (cipso_v4_doi_search(doi) != NULL) {
496 spin_lock(&cipso_v4_doi_list_lock);

--- 4 unchanged lines hidden (view full) ---

501 return -ENOENT;
502 }
503 doi_def->valid = 0;
504 list_del_rcu(&doi_def->list);
505 spin_unlock(&cipso_v4_doi_list_lock);
506 list_for_each_entry_rcu(dom_iter, &doi_def->dom_list, list)
507 if (dom_iter->valid)
508 netlbl_domhsh_remove(dom_iter->domain,
489 void (*callback) (struct rcu_head * head))
490{
491 struct cipso_v4_doi *doi_def;
492 struct cipso_v4_domhsh_entry *dom_iter;
493
494 rcu_read_lock();
495 if (cipso_v4_doi_search(doi) != NULL) {
496 spin_lock(&cipso_v4_doi_list_lock);

--- 4 unchanged lines hidden (view full) ---

501 return -ENOENT;
502 }
503 doi_def->valid = 0;
504 list_del_rcu(&doi_def->list);
505 spin_unlock(&cipso_v4_doi_list_lock);
506 list_for_each_entry_rcu(dom_iter, &doi_def->dom_list, list)
507 if (dom_iter->valid)
508 netlbl_domhsh_remove(dom_iter->domain,
509 audit_secid);
509 audit_info);
510 cipso_v4_cache_invalidate();
511 rcu_read_unlock();
512
513 call_rcu(&doi_def->rcu, callback);
514 return 0;
515 }
516 rcu_read_unlock();
517

--- 957 unchanged lines hidden ---
510 cipso_v4_cache_invalidate();
511 rcu_read_unlock();
512
513 call_rcu(&doi_def->rcu, callback);
514 return 0;
515 }
516 rcu_read_unlock();
517

--- 957 unchanged lines hidden ---