--- tar-1.15.1/src/common.h.mangling 2006-12-04 12:47:40.000000000 +0100 +++ tar-1.15.1/src/common.h 2006-12-04 12:47:40.000000000 +0100 @@ -124,6 +124,9 @@ GLOBAL bool absolute_names_option; +/* Allow GNUTYPE_NAMES type? */ +GLOBAL bool allow_name_mangling_option; + /* Display file times in UTC */ GLOBAL bool utc_option; --- tar-1.15.1/src/extract.c.mangling 2006-12-04 12:47:40.000000000 +0100 +++ tar-1.15.1/src/extract.c 2006-12-04 12:47:40.000000000 +0100 @@ -1171,7 +1171,13 @@ break; case GNUTYPE_NAMES: - extract_mangle (); + if (allow_name_mangling_option) { + extract_mangle (); + } + else { + ERROR ((0, 0, _("GNUTYPE_NAMES mangling ignored"))); + skip_member (); + } break; case GNUTYPE_MULTIVOL: --- tar-1.15.1/src/tar.c.mangling 2006-12-04 12:47:40.000000000 +0100 +++ tar-1.15.1/src/tar.c 2006-12-04 12:55:35.000000000 +0100 @@ -182,6 +182,7 @@ { ACLS_OPTION = CHAR_MAX + 1, ANCHORED_OPTION, + ALLOW_NAME_MANGLING_OPTION, ATIME_PRESERVE_OPTION, BACKUP_OPTION, CHECKPOINT_OPTION, @@ -546,6 +547,8 @@ {NULL, 'o', 0, 0, N_("when creating, same as --old-archive. When extracting, same as --no-same-owner"), 91 }, + {"allow-name-mangling", ALLOW_NAME_MANGLING_OPTION, 0, 0, + N_("when creating, allow GNUTYPE_NAMES mangling -- considered dangerous"), 91 }, {NULL, 0, NULL, 0, N_("Other options:"), 100 }, @@ -931,6 +934,10 @@ case 'Z': set_use_compress_program_option ("compress"); break; + + case ALLOW_NAME_MANGLING_OPTION: + allow_name_mangling_option = true; + break; case ANCHORED_OPTION: args->exclude_options |= EXCLUDE_ANCHORED;