Add doc and docx rest test to mapper attachment along with
getClassLoader permission
This commit is contained in:
parent
51d87d94dc
commit
2f3efc3fe1
|
@ -374,7 +374,8 @@ public abstract class FieldMapper extends Mapper implements Cloneable {
|
|||
// this can happen if this mapper represents a mapping update
|
||||
return this;
|
||||
} else if (fieldType.getClass() != newFieldType.getClass()) {
|
||||
throw new IllegalStateException("Mixing up field types: " + fieldType.getClass() + " != " + newFieldType.getClass());
|
||||
throw new IllegalStateException("Mixing up field types: " +
|
||||
fieldType.getClass() + " != " + newFieldType.getClass() + " on field " + fieldType.name());
|
||||
}
|
||||
MultiFields updatedMultiFields = multiFields.updateFieldType(fullNameToFieldType);
|
||||
if (fieldType == newFieldType && multiFields == updatedMultiFields) {
|
||||
|
|
|
@ -137,6 +137,8 @@ final class TikaImpl {
|
|||
perms.add(new SecurityPermission("putProviderProperty.BC"));
|
||||
perms.add(new SecurityPermission("insertProvider"));
|
||||
perms.add(new ReflectPermission("suppressAccessChecks"));
|
||||
// xmlbeans, use by POI, needs to get the context classloader
|
||||
perms.add(new RuntimePermission("getClassLoader"));
|
||||
perms.setReadOnly();
|
||||
return perms;
|
||||
}
|
||||
|
|
|
@ -27,4 +27,6 @@ grant {
|
|||
permission java.security.SecurityPermission "insertProvider";
|
||||
// TODO: fix POI XWPF to not do this: https://bz.apache.org/bugzilla/show_bug.cgi?id=58597
|
||||
permission java.lang.reflect.ReflectPermission "suppressAccessChecks";
|
||||
// needed by xmlbeans, as part of POI for MS xml docs
|
||||
permission java.lang.RuntimePermission "getClassLoader";
|
||||
};
|
||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue