diff options
author | Sven Gothel <[email protected]> | 2013-06-20 20:09:43 +0200 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2013-06-20 20:09:43 +0200 |
commit | 12b3084ecc9da5b768fb7c9a9180d54b3d24ee43 (patch) | |
tree | 5d44696c07f6a14d72024b44bb214bbe2b18e939 /make/joal-alextabstract-CustomJavaCode.java | |
parent | 55b5449ce106164e7f47b827cbe03a7831de9942 (diff) |
Security: Tighten DynamicLinker*, NativeLibrary and DynamicLibraryBundle access.
Diffstat (limited to 'make/joal-alextabstract-CustomJavaCode.java')
-rw-r--r-- | make/joal-alextabstract-CustomJavaCode.java | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/make/joal-alextabstract-CustomJavaCode.java b/make/joal-alextabstract-CustomJavaCode.java index e73dc60..e467fc7 100644 --- a/make/joal-alextabstract-CustomJavaCode.java +++ b/make/joal-alextabstract-CustomJavaCode.java @@ -1,11 +1,15 @@ private static final ALExtProcAddressTable alExtProcAddressTable; static { - alExtProcAddressTable = new ALExtProcAddressTable(); - if(null==alExtProcAddressTable) { - throw new RuntimeException("Couldn't instantiate ALExtProcAddressTable"); - } - alExtProcAddressTable.reset(ALImpl.alDynamicLookupHelper); + alExtProcAddressTable = AccessController.doPrivileged(new PrivilegedAction<ALExtProcAddressTable>() { + public ALExtProcAddressTable run() { + final ALExtProcAddressTable alExtProcAddressTable = new ALExtProcAddressTable(); + if(null==alExtProcAddressTable) { + throw new RuntimeException("Couldn't instantiate ALExtProcAddressTable"); + } + alExtProcAddressTable.reset(ALImpl.alDynamicLookupHelper); + return alExtProcAddressTable; + } } ); } public static ALExtProcAddressTable getALExtProcAddressTable() { return alExtProcAddressTable; } |