Skip to content

Commit f2bca9f

Browse files
Merge
2 parents 6900d29 + 90289a2 commit f2bca9f

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+1110
-843
lines changed

doc-files/release-notes-14.md

+81
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
# Release Notes for JavaFX 14
2+
3+
## Introduction
4+
5+
The following notes describe important changes and information about this release. In some cases, the descriptions provide links to additional detailed information about an issue or a change.
6+
7+
As of JDK 11 the JavaFX modules are delivered separately from the JDK. These release notes cover the standalone JavaFX 14 release. JavaFX 14 requires JDK 11 or later.
8+
9+
## List of Fixed Bugs
10+
11+
Issue key|Summary|Subcomponent
12+
---------|-------|------------
13+
[JDK-8237975](https://bugs.openjdk.java.net/browse/JDK-8237975) | Non-embedded Animations do not play backwards after being paused | animation
14+
[JDK-8236753](https://bugs.openjdk.java.net/browse/JDK-8236753) | Animations do not play backwards after being stopped | animation
15+
[JDK-8232524](https://bugs.openjdk.java.net/browse/JDK-8232524) | SynchronizedObservableMap cannot be be protected for copying/iterating | base
16+
[JDK-8220396](https://bugs.openjdk.java.net/browse/JDK-8220396) | Bindings class gives a lot of unneeded 'select-binding' log messages | base
17+
[JDK-8229472](https://bugs.openjdk.java.net/browse/JDK-8229472) | Deprecate for removal JavaBeanXxxPropertyBuilders constructors | base
18+
[JDK-8207774](https://bugs.openjdk.java.net/browse/JDK-8207774) | TextField: must not forward ENTER if actionHandler consumed the actionEvent | controls
19+
[JDK-8207759](https://bugs.openjdk.java.net/browse/JDK-8207759) | VK_ENTER not consumed by TextField when default Button exists | controls
20+
[JDK-8179097](https://bugs.openjdk.java.net/browse/JDK-8179097) | NPE in MenuButtonSkinBase class | controls
21+
[JDK-8185937](https://bugs.openjdk.java.net/browse/JDK-8185937) | Spinner with Double/Integer value factory ignores up/down arrow keys | controls
22+
[JDK-8233040](https://bugs.openjdk.java.net/browse/JDK-8233040) | ComboBoxPopupControl: remove eventFilter for F4 | controls
23+
[JDK-8232811](https://bugs.openjdk.java.net/browse/JDK-8232811) | Dialog's preferred size no longer accommodates multi-line strings | controls
24+
[JDK-8221334](https://bugs.openjdk.java.net/browse/JDK-8221334) | TableViewSkin: must initialize flow's cellCount in constructor | controls
25+
[JDK-8220722](https://bugs.openjdk.java.net/browse/JDK-8220722) | ProgressBarSkin: adds strong listener to control's width property | controls
26+
[JDK-8237372](https://bugs.openjdk.java.net/browse/JDK-8237372) | NullPointerException in TabPaneSkin.stopDrag | controls
27+
[JDK-8193445](https://bugs.openjdk.java.net/browse/JDK-8193445) | JavaFX CSS is applied redundantly leading to significant performance degradation | controls
28+
[JDK-8196587](https://bugs.openjdk.java.net/browse/JDK-8196587) | Remove use of deprecated finalize method from JPEGImageLoader | graphics
29+
[JDK-8166194](https://bugs.openjdk.java.net/browse/JDK-8166194) | JavaFX: poor printing quality for Region nodes | graphics
30+
[JDK-8189092](https://bugs.openjdk.java.net/browse/JDK-8189092) | ArrayIndexOutOfBoundsException on Linux in getCachedGlyph | graphics
31+
[JDK-8236448](https://bugs.openjdk.java.net/browse/JDK-8236448) | Remove unused and repair broken Android/Dalvik code | graphics
32+
[JDK-8236484](https://bugs.openjdk.java.net/browse/JDK-8236484) | Compile error in monocle dispman | graphics
33+
[JDK-8232687](https://bugs.openjdk.java.net/browse/JDK-8232687) | No static JNI loader for libprism-sw | graphics
34+
[JDK-8232943](https://bugs.openjdk.java.net/browse/JDK-8232943) | Gesture support is not initialized on iOS | graphics
35+
[JDK-8232929](https://bugs.openjdk.java.net/browse/JDK-8232929) | Duplicate symbols when building static libraries | graphics
36+
[JDK-8232210](https://bugs.openjdk.java.net/browse/JDK-8232210) | Update Mesa 3-D Headers to version 19.2.1 | graphics
37+
[JDK-8235151](https://bugs.openjdk.java.net/browse/JDK-8235151) | Nonexistent notifyQuit method referred from iOS GlassHelper.m | graphics
38+
[JDK-8235150](https://bugs.openjdk.java.net/browse/JDK-8235150) | IosApplication does not pass the required object in _leaveNestedEventLoopImpl | graphics
39+
[JDK-8235627](https://bugs.openjdk.java.net/browse/JDK-8235627) | Blank stages when running JavaFX app in a macOS virtual machine | graphics
40+
[JDK-8234916](https://bugs.openjdk.java.net/browse/JDK-8234916) | [macos 10.15] Garbled text running with native-image | graphics
41+
[JDK-8223296](https://bugs.openjdk.java.net/browse/JDK-8223296) | NullPointerException in GlassScene.java at line 325 | graphics
42+
[JDK-8236808](https://bugs.openjdk.java.net/browse/JDK-8236808) | javafx_iio can not be used in static environment | graphics
43+
[JDK-8088198](https://bugs.openjdk.java.net/browse/JDK-8088198) | Exception thrown from snapshot if dimensions are larger than max texture size | graphics
44+
[JDK-8232589](https://bugs.openjdk.java.net/browse/JDK-8232589) | Remove CoreAudio Utility Classes | media
45+
[JDK-8230610](https://bugs.openjdk.java.net/browse/JDK-8230610) | Upgrade GStreamer to version 1.16.1 | media
46+
[JDK-8230609](https://bugs.openjdk.java.net/browse/JDK-8230609) | Upgrade glib to version 2.62.2 | media
47+
[JDK-8233338](https://bugs.openjdk.java.net/browse/JDK-8233338) | FX javadoc headings are out of sequence | other
48+
[JDK-8232824](https://bugs.openjdk.java.net/browse/JDK-8232824) | Removing TabPane with strong referenced content causes memory leak from weak one | scenegraph
49+
[JDK-8200224](https://bugs.openjdk.java.net/browse/JDK-8200224) | First mouse press each time JFXPanel gains focus is triggered twice | swing
50+
[JDK-8218640](https://bugs.openjdk.java.net/browse/JDK-8218640) | Update ICU4C to version 64.2 | web
51+
[JDK-8233747](https://bugs.openjdk.java.net/browse/JDK-8233747) | JVM crash in com.sun.webkit.dom.DocumentImpl.createAttribute | web
52+
[JDK-8230492](https://bugs.openjdk.java.net/browse/JDK-8230492) | font-family not set in HTMLEditor if font name has a number in it | web
53+
[JDK-8236912](https://bugs.openjdk.java.net/browse/JDK-8236912) | NullPointerException when clicking in WebView with Button 4 or Button 5 | web
54+
[JDK-8231188](https://bugs.openjdk.java.net/browse/JDK-8231188) | Update SQLite to version 3.30.1 | web
55+
[JDK-8234056](https://bugs.openjdk.java.net/browse/JDK-8234056) | Upgrade to libxslt 1.1.34 | web
56+
[JDK-8231513](https://bugs.openjdk.java.net/browse/JDK-8231513) | JavaFX cause Keystroke Receiving prompt on MacOS 10.15 (Catalina) | window-toolkit
57+
[JDK-8234474](https://bugs.openjdk.java.net/browse/JDK-8234474) | [macos 10.15] Crash in file dialog in sandbox mode | window-toolkit
58+
[JDK-8228766](https://bugs.openjdk.java.net/browse/JDK-8228766) | Platform.startup() deadlock on mac when called from class initializer | window-toolkit
59+
[JDK-8227366](https://bugs.openjdk.java.net/browse/JDK-8227366) | Wrong stage gets focused after modal stage creation | window-toolkit
60+
61+
## List of Enhancements
62+
63+
Issue key|Summary|Subcomponent
64+
---------|-------|------------
65+
[JDK-8207957](https://bugs.openjdk.java.net/browse/JDK-8207957) | TableSkinUtils should not contain actual code implementation | controls
66+
[JDK-8130738](https://bugs.openjdk.java.net/browse/JDK-8130738) | Add tabSize property to Text and TextFlow | graphics
67+
[JDK-8226850](https://bugs.openjdk.java.net/browse/JDK-8226850) | Use an EnumSet for DirtyBits instead of an ordinal-based mask | graphics
68+
[JDK-8092352](https://bugs.openjdk.java.net/browse/JDK-8092352) | Skip event dispatch if there are no handlers/filters | scenegraph
69+
[JDK-8211308](https://bugs.openjdk.java.net/browse/JDK-8211308) | Support HTTP/2 in WebView | web
70+
[JDK-8087980](https://bugs.openjdk.java.net/browse/JDK-8087980) | Add property to disable Monocle cursor | window-toolkit
71+
[JDK-8225571](https://bugs.openjdk.java.net/browse/JDK-8225571) | Port Linux glass drag source (DND) to use gtk instead of gdk | window-toolkit
72+
73+
## List of Security fixes
74+
75+
Issue key|Summary|Subcomponent
76+
---------|-------|------------
77+
JDK-8227473 (not public) | Improve gstreamer media support | media
78+
JDK-8227402 (not public) | Improve XSLT processing | web
79+
JDK-8232121 (not public) | Better numbering system | web
80+
JDK-8232128 (not public) | Better formatting for numbers | web
81+
JDK-8232214 (not public) | Improved internal validations | web

modules/javafx.base/src/main/java/javafx/beans/property/adapter/JavaBeanBooleanPropertyBuilder.java

+1-5
Original file line numberDiff line numberDiff line change
@@ -61,11 +61,7 @@ public final class JavaBeanBooleanPropertyBuilder {
6161

6262
private final JavaBeanPropertyBuilderHelper helper = new JavaBeanPropertyBuilderHelper();
6363

64-
/**
65-
* @deprecated This constructor was exposed erroneously and will be removed in the next version. Use {@link #create()} instead.
66-
*/
67-
@Deprecated(since="14", forRemoval=true)
68-
public JavaBeanBooleanPropertyBuilder() {}
64+
private JavaBeanBooleanPropertyBuilder() {}
6965

7066
/**
7167
* Creates a new instance of {@code JavaBeanBooleanPropertyBuilder}.

modules/javafx.base/src/main/java/javafx/beans/property/adapter/JavaBeanDoublePropertyBuilder.java

+1-5
Original file line numberDiff line numberDiff line change
@@ -61,11 +61,7 @@ public final class JavaBeanDoublePropertyBuilder {
6161

6262
private final JavaBeanPropertyBuilderHelper helper = new JavaBeanPropertyBuilderHelper();
6363

64-
/**
65-
* @deprecated This constructor was exposed erroneously and will be removed in the next version. Use {@link #create()} instead.
66-
*/
67-
@Deprecated(since="14", forRemoval=true)
68-
public JavaBeanDoublePropertyBuilder() {}
64+
private JavaBeanDoublePropertyBuilder() {}
6965

7066
/**
7167
* Creates a new instance of {@code JavaBeanDoublePropertyBuilder}.

modules/javafx.base/src/main/java/javafx/beans/property/adapter/JavaBeanFloatPropertyBuilder.java

+1-5
Original file line numberDiff line numberDiff line change
@@ -61,11 +61,7 @@ public final class JavaBeanFloatPropertyBuilder {
6161

6262
private JavaBeanPropertyBuilderHelper helper = new JavaBeanPropertyBuilderHelper();
6363

64-
/**
65-
* @deprecated This constructor was exposed erroneously and will be removed in the next version. Use {@link #create()} instead.
66-
*/
67-
@Deprecated(since="14", forRemoval=true)
68-
public JavaBeanFloatPropertyBuilder() {}
64+
private JavaBeanFloatPropertyBuilder() {}
6965

7066
/**
7167
* Creates a new instance of {@code JavaBeanFloatPropertyBuilder}.

modules/javafx.base/src/main/java/javafx/beans/property/adapter/JavaBeanIntegerPropertyBuilder.java

+1-5
Original file line numberDiff line numberDiff line change
@@ -61,11 +61,7 @@ public final class JavaBeanIntegerPropertyBuilder {
6161

6262
private JavaBeanPropertyBuilderHelper helper = new JavaBeanPropertyBuilderHelper();
6363

64-
/**
65-
* @deprecated This constructor was exposed erroneously and will be removed in the next version. Use {@link #create()} instead.
66-
*/
67-
@Deprecated(since="14", forRemoval=true)
68-
public JavaBeanIntegerPropertyBuilder() {}
64+
private JavaBeanIntegerPropertyBuilder() {}
6965

7066
/**
7167
* Creates a new instance of {@code JavaBeanIntegerPropertyBuilder}.

modules/javafx.base/src/main/java/javafx/beans/property/adapter/JavaBeanLongPropertyBuilder.java

+1-5
Original file line numberDiff line numberDiff line change
@@ -61,11 +61,7 @@ public final class JavaBeanLongPropertyBuilder {
6161

6262
private JavaBeanPropertyBuilderHelper helper = new JavaBeanPropertyBuilderHelper();
6363

64-
/**
65-
* @deprecated This constructor was exposed erroneously and will be removed in the next version. Use {@link #create()} instead.
66-
*/
67-
@Deprecated(since="14", forRemoval=true)
68-
public JavaBeanLongPropertyBuilder() {}
64+
private JavaBeanLongPropertyBuilder() {}
6965

7066
/**
7167
* Creates a new instance of {@code JavaBeanLongPropertyBuilder}.

modules/javafx.base/src/main/java/javafx/beans/property/adapter/JavaBeanObjectPropertyBuilder.java

+1-5
Original file line numberDiff line numberDiff line change
@@ -63,11 +63,7 @@ public final class JavaBeanObjectPropertyBuilder<T> {
6363

6464
private JavaBeanPropertyBuilderHelper helper = new JavaBeanPropertyBuilderHelper();
6565

66-
/**
67-
* @deprecated This constructor was exposed erroneously and will be removed in the next version. Use {@link #create()} instead.
68-
*/
69-
@Deprecated(since="14", forRemoval=true)
70-
public JavaBeanObjectPropertyBuilder() {}
66+
private JavaBeanObjectPropertyBuilder() {}
7167

7268
/**
7369
* Creates a new instance of {@code JavaBeanObjectPropertyBuilder}.

modules/javafx.base/src/main/java/javafx/beans/property/adapter/JavaBeanStringPropertyBuilder.java

+1-5
Original file line numberDiff line numberDiff line change
@@ -61,11 +61,7 @@ public final class JavaBeanStringPropertyBuilder {
6161

6262
private JavaBeanPropertyBuilderHelper helper = new JavaBeanPropertyBuilderHelper();
6363

64-
/**
65-
* @deprecated This constructor was exposed erroneously and will be removed in the next version. Use {@link #create()} instead.
66-
*/
67-
@Deprecated(since="14", forRemoval=true)
68-
public JavaBeanStringPropertyBuilder() {}
64+
private JavaBeanStringPropertyBuilder() {}
6965

7066
/**
7167
* Creates a new instance of {@code JavaBeanStringPropertyBuilder}.

modules/javafx.base/src/main/java/javafx/beans/property/adapter/ReadOnlyJavaBeanBooleanPropertyBuilder.java

+1-5
Original file line numberDiff line numberDiff line change
@@ -60,11 +60,7 @@ public final class ReadOnlyJavaBeanBooleanPropertyBuilder {
6060

6161
private final ReadOnlyJavaBeanPropertyBuilderHelper helper = new ReadOnlyJavaBeanPropertyBuilderHelper();
6262

63-
/**
64-
* @deprecated This constructor was exposed erroneously and will be removed in the next version. Use {@link #create()} instead.
65-
*/
66-
@Deprecated(since="14", forRemoval=true)
67-
public ReadOnlyJavaBeanBooleanPropertyBuilder() {}
63+
private ReadOnlyJavaBeanBooleanPropertyBuilder() {}
6864

6965
/**
7066
* Create a new instance of {@code ReadOnlyJavaBeanBooleanPropertyBuilder}

modules/javafx.base/src/main/java/javafx/beans/property/adapter/ReadOnlyJavaBeanDoublePropertyBuilder.java

+1-5
Original file line numberDiff line numberDiff line change
@@ -60,11 +60,7 @@ public final class ReadOnlyJavaBeanDoublePropertyBuilder {
6060

6161
private final ReadOnlyJavaBeanPropertyBuilderHelper helper = new ReadOnlyJavaBeanPropertyBuilderHelper();
6262

63-
/**
64-
* @deprecated This constructor was exposed erroneously and will be removed in the next version. Use {@link #create()} instead.
65-
*/
66-
@Deprecated(since="14", forRemoval=true)
67-
public ReadOnlyJavaBeanDoublePropertyBuilder() {}
63+
private ReadOnlyJavaBeanDoublePropertyBuilder() {}
6864

6965
/**
7066
* Create a new instance of {@code ReadOnlyJavaBeanDoublePropertyBuilder}

modules/javafx.base/src/main/java/javafx/beans/property/adapter/ReadOnlyJavaBeanFloatPropertyBuilder.java

+1-5
Original file line numberDiff line numberDiff line change
@@ -60,11 +60,7 @@ public final class ReadOnlyJavaBeanFloatPropertyBuilder {
6060

6161
private final ReadOnlyJavaBeanPropertyBuilderHelper helper = new ReadOnlyJavaBeanPropertyBuilderHelper();
6262

63-
/**
64-
* @deprecated This constructor was exposed erroneously and will be removed in the next version. Use {@link #create()} instead.
65-
*/
66-
@Deprecated(since="14", forRemoval=true)
67-
public ReadOnlyJavaBeanFloatPropertyBuilder() {}
63+
private ReadOnlyJavaBeanFloatPropertyBuilder() {}
6864

6965
/**
7066
* Create a new instance of {@code ReadOnlyJavaBeanFloatPropertyBuilder}

modules/javafx.base/src/main/java/javafx/beans/property/adapter/ReadOnlyJavaBeanIntegerPropertyBuilder.java

+1-5
Original file line numberDiff line numberDiff line change
@@ -60,11 +60,7 @@ public final class ReadOnlyJavaBeanIntegerPropertyBuilder {
6060

6161
private final ReadOnlyJavaBeanPropertyBuilderHelper helper = new ReadOnlyJavaBeanPropertyBuilderHelper();
6262

63-
/**
64-
* @deprecated This constructor was exposed erroneously and will be removed in the next version. Use {@link #create()} instead.
65-
*/
66-
@Deprecated(since="14", forRemoval=true)
67-
public ReadOnlyJavaBeanIntegerPropertyBuilder() {}
63+
private ReadOnlyJavaBeanIntegerPropertyBuilder() {}
6864

6965
/**
7066
* Create a new instance of {@code ReadOnlyJavaBeanIntegerPropertyBuilder}

modules/javafx.base/src/main/java/javafx/beans/property/adapter/ReadOnlyJavaBeanLongPropertyBuilder.java

+1-5
Original file line numberDiff line numberDiff line change
@@ -60,11 +60,7 @@ public final class ReadOnlyJavaBeanLongPropertyBuilder {
6060

6161
private final ReadOnlyJavaBeanPropertyBuilderHelper helper = new ReadOnlyJavaBeanPropertyBuilderHelper();
6262

63-
/**
64-
* @deprecated This constructor was exposed erroneously and will be removed in the next version. Use {@link #create()} instead.
65-
*/
66-
@Deprecated(since="14", forRemoval=true)
67-
public ReadOnlyJavaBeanLongPropertyBuilder() {}
63+
private ReadOnlyJavaBeanLongPropertyBuilder() {}
6864

6965
/**
7066
* Create a new instance of {@code ReadOnlyJavaBeanLongPropertyBuilder}

modules/javafx.base/src/main/java/javafx/beans/property/adapter/ReadOnlyJavaBeanObjectPropertyBuilder.java

+1-5
Original file line numberDiff line numberDiff line change
@@ -62,11 +62,7 @@ public final class ReadOnlyJavaBeanObjectPropertyBuilder<T> {
6262

6363
private final ReadOnlyJavaBeanPropertyBuilderHelper helper = new ReadOnlyJavaBeanPropertyBuilderHelper();
6464

65-
/**
66-
* @deprecated This constructor was exposed erroneously and will be removed in the next version. Use {@link #create()} instead.
67-
*/
68-
@Deprecated(since="14", forRemoval=true)
69-
public ReadOnlyJavaBeanObjectPropertyBuilder() {}
65+
private ReadOnlyJavaBeanObjectPropertyBuilder() {}
7066

7167
/**
7268
* Create a new instance of {@code ReadOnlyJavaBeanObjectPropertyBuilder}

modules/javafx.base/src/main/java/javafx/beans/property/adapter/ReadOnlyJavaBeanStringPropertyBuilder.java

+1-5
Original file line numberDiff line numberDiff line change
@@ -60,11 +60,7 @@ public final class ReadOnlyJavaBeanStringPropertyBuilder {
6060

6161
private final ReadOnlyJavaBeanPropertyBuilderHelper helper = new ReadOnlyJavaBeanPropertyBuilderHelper();
6262

63-
/**
64-
* @deprecated This constructor was exposed erroneously and will be removed in the next version. Use {@link #create()} instead.
65-
*/
66-
@Deprecated(since="14", forRemoval=true)
67-
public ReadOnlyJavaBeanStringPropertyBuilder() {}
63+
private ReadOnlyJavaBeanStringPropertyBuilder() {}
6864

6965
/**
7066
* Create a new instance of {@code ReadOnlyJavaBeanStringPropertyBuilder}

modules/javafx.controls/src/main/java/javafx/scene/control/skin/ProgressIndicatorSkin.java

+8-1
Original file line numberDiff line numberDiff line change
@@ -324,7 +324,10 @@ Paint getProgressColor() {
324324
void initialize() {
325325
boolean isIndeterminate = control.isIndeterminate();
326326
if (isIndeterminate) {
327-
// clean up determinateIndicator
327+
// clean up the old determinateIndicator
328+
if (determinateIndicator != null) {
329+
determinateIndicator.unregisterListener();
330+
}
328331
determinateIndicator = null;
329332

330333
// create spinner
@@ -541,6 +544,10 @@ public DeterminateIndicator(ProgressIndicator control, ProgressIndicatorSkin s,
541544
updateProgress(control.getProgress());
542545
}
543546

547+
private void unregisterListener() {
548+
unregisterChangeListeners(text.fontProperty());
549+
}
550+
544551
private void setFillOverride(Paint fillOverride) {
545552
if (fillOverride instanceof Color) {
546553
Color c = (Color)fillOverride;

modules/javafx.graphics/src/main/legal/jpeg_fx.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## Independent JPEG Group (IJG) JPEG v9c
1+
## Independent JPEG Group (IJG) JPEG v9d
22

33
### IJG License
44
```
@@ -18,7 +18,7 @@ with respect to this software, its quality, accuracy, merchantability, or
1818
fitness for a particular purpose. This software is provided "AS IS", and you,
1919
its user, assume the entire risk as to its quality and accuracy.
2020
21-
This software is copyright (C) 1991-2018, Thomas G. Lane, Guido Vollbeding.
21+
This software is copyright (C) 1991-2020, Thomas G. Lane, Guido Vollbeding.
2222
All Rights Reserved except as specified below.
2323
2424
Permission is hereby granted to use, copy, modify, and distribute this

modules/javafx.graphics/src/main/native-glass/mac/GlassApplication.h

-2
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,4 @@
6060

6161
+ (BOOL)syncRenderingDisabled;
6262

63-
+ (BOOL)isSandboxed;
64-
6563
@end

modules/javafx.graphics/src/main/native-glass/mac/GlassApplication.m

-38
Original file line numberDiff line numberDiff line change
@@ -755,44 +755,6 @@ + (BOOL)syncRenderingDisabled {
755755
return disableSyncRendering;
756756
}
757757

758-
+ (BOOL)isSandboxed
759-
{
760-
static int isSandboxed = -1;
761-
762-
if (isSandboxed == -1) {
763-
isSandboxed = 0;
764-
765-
NSBundle *mainBundle = [NSBundle mainBundle];
766-
NSURL *url = [mainBundle bundleURL];
767-
SecStaticCodeRef staticCodeRef = NULL;
768-
SecStaticCodeCreateWithPath((CFURLRef)url, kSecCSDefaultFlags, &staticCodeRef);
769-
770-
if (staticCodeRef) {
771-
// Check if the app is signed
772-
OSStatus res_signed = SecStaticCodeCheckValidityWithErrors(staticCodeRef, kSecCSBasicValidateOnly, NULL, NULL);
773-
if (res_signed == errSecSuccess) {
774-
// It is signed, now check if it's sandboxed
775-
SecRequirementRef sandboxRequirementRef = NULL;
776-
SecRequirementCreateWithString(CFSTR("entitlement[\"com.apple.security.app-sandbox\"] exists"), kSecCSDefaultFlags, &sandboxRequirementRef);
777-
778-
if (sandboxRequirementRef) {
779-
OSStatus res_sandboxed = SecStaticCodeCheckValidityWithErrors(staticCodeRef, kSecCSBasicValidateOnly, sandboxRequirementRef, NULL);
780-
if (res_sandboxed == errSecSuccess) {
781-
// Yep, sandboxed
782-
isSandboxed = 1;
783-
}
784-
785-
CFRelease(sandboxRequirementRef);
786-
}
787-
}
788-
789-
CFRelease(staticCodeRef);
790-
}
791-
}
792-
793-
return isSandboxed == 1 ? YES : NO;
794-
}
795-
796758
@end
797759

798760
#pragma mark --- JNI

0 commit comments

Comments
 (0)