- Timestamp:
- Mar 14, 2006, 10:42:10 PM (19 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/configure.ac
r19 r26 763 763 ;; 764 764 *) 765 AM_PATH_LIBPRELUDE([0.9. 0],765 AM_PATH_LIBPRELUDE([0.9.6], 766 766 [ 767 767 AC_DEFINE(HAVE_LIBPRELUDE,1,[Have libprelude]) -
trunk/src/sh_prelude.c
r22 r26 138 138 char * dup = strdup (str); 139 139 140 if (!dup) 141 return -1; 142 140 143 p = strtok (dup, ", \t"); 141 142 144 if (p) { 143 145 do { … … 158 160 else if (0 == strcmp (p, _("info"))) 159 161 clear_and_set (prelude_sev, SH_ERR_INFO); 160 else 162 else { 163 free (dup); 161 164 return -1; 165 } 162 166 p = strtok (NULL, ", \t"); 163 167 } while (p); … … 314 318 if ( mode[pos] == 'r' ) { 315 319 /* flawfinder: ignore *//* is part of name, not access() */ 316 ret = idmef_file_access_new_permission(access, &str, -1);320 ret = idmef_file_access_new_permission(access, &str, IDMEF_LIST_APPEND); 317 321 if ( ret < 0 ) 318 322 return; … … 322 326 else if ( mode[pos] == 'w' ) { 323 327 /* flawfinder: ignore *//* is part of name, not access() */ 324 ret = idmef_file_access_new_permission(access, &str, -1);328 ret = idmef_file_access_new_permission(access, &str, IDMEF_LIST_APPEND); 325 329 if ( ret < 0 ) 326 330 return; … … 330 334 else if ( mode[pos] == 'x' || mode[pos] == 's' || mode[pos] == 't') { 331 335 /* flawfinder: ignore *//* is part of name, not access() */ 332 ret = idmef_file_access_new_permission(access, &str, -1);336 ret = idmef_file_access_new_permission(access, &str, IDMEF_LIST_APPEND); 333 337 if ( ret < 0 ) 334 338 return; … … 349 353 if ( got == 0 ) { 350 354 /* flawfinder: ignore *//* is part of name, not access() */ 351 ret = idmef_file_access_new_permission(access, &str, -1);355 ret = idmef_file_access_new_permission(access, &str, IDMEF_LIST_APPEND); 352 356 if ( ret < 0 ) 353 357 return; … … 374 378 char *mode = NULL; 375 379 376 ret = idmef_target_new_file(target, &file, -1);380 ret = idmef_target_new_file(target, &file, IDMEF_LIST_APPEND); 377 381 if ( ret < 0 ) 378 382 return; … … 438 442 ptr = get_value(msg, _("chksum"), suffix); 439 443 if ( ptr ) { 440 ret = idmef_file_new_checksum(file, &checksum, 0);444 ret = idmef_file_new_checksum(file, &checksum, IDMEF_LIST_APPEND); 441 445 if ( ret < 0 ) 442 446 return; … … 469 473 if ( mode ) { 470 474 /* flawfinder: ignore *//* is part of name, not access() */ 471 ret = idmef_file_new_file_access(file, &access, -1);475 ret = idmef_file_new_file_access(file, &access, IDMEF_LIST_APPEND); 472 476 if ( ret < 0 ) 473 477 return; … … 488 492 489 493 /* flawfinder: ignore *//* is part of name, not access() */ 490 ret = idmef_file_new_file_access(file, &access, 0);494 ret = idmef_file_new_file_access(file, &access, IDMEF_LIST_APPEND); 491 495 if ( ret < 0 ) 492 496 return; … … 521 525 522 526 /* flawfinder: ignore *//* is part of name, not access() */ 523 ret = idmef_file_new_file_access(file, &access, -1);527 ret = idmef_file_new_file_access(file, &access, IDMEF_LIST_APPEND); 524 528 if ( ret < 0 ) 525 529 return; … … 646 650 if ( ptr ) { 647 651 if ( ! source ) { 648 ret = idmef_alert_new_source(alert, &source, -1);652 ret = idmef_alert_new_source(alert, &source, IDMEF_LIST_APPEND); 649 653 if ( ret < 0 ) { 650 654 free(ptr); … … 659 663 } 660 664 661 ret = idmef_node_new_address(node, &address, -1);665 ret = idmef_node_new_address(node, &address, IDMEF_LIST_APPEND); 662 666 if ( ret < 0 ) { 663 667 free(ptr); … … 680 684 else { 681 685 if ( ! source ) { 682 ret = idmef_alert_new_source(alert, &source, -1);686 ret = idmef_alert_new_source(alert, &source, IDMEF_LIST_APPEND); 683 687 if ( ret < 0 ) { 684 688 free(ptr); … … 713 717 idmef_user_set_category(user, IDMEF_USER_CATEGORY_OS_DEVICE); 714 718 715 ret = idmef_user_new_user_id(user, &user_id, -1);719 ret = idmef_user_new_user_id(user, &user_id, IDMEF_LIST_APPEND); 716 720 if ( ret < 0 ) { 717 721 free(ptr); … … 787 791 goto err; 788 792 789 idmef_alert_set_analyzer(alert, idmef_analyzer_ref(prelude_client_get_analyzer(client)), 0);793 idmef_alert_set_analyzer(alert, idmef_analyzer_ref(prelude_client_get_analyzer(client)), IDMEF_LIST_PREPEND); 790 794 791 795 ret = idmef_time_new_from_gettimeofday(&time); … … 803 807 goto err; 804 808 805 ret = idmef_alert_new_target(alert, &target, -1);809 ret = idmef_alert_new_target(alert, &target, IDMEF_LIST_APPEND); 806 810 if ( ret < 0 ) 807 811 goto err; … … 861 865 idmef_confidence_set_rating(confidence, IDMEF_CONFIDENCE_RATING_HIGH); 862 866 863 ret = idmef_alert_new_additional_data(alert, &data, -1);867 ret = idmef_alert_new_additional_data(alert, &data, IDMEF_LIST_APPEND); 864 868 if ( ret < 0 ) 865 869 goto err;
Note:
See TracChangeset
for help on using the changeset viewer.