instruction
string | input
string | output
string | cwe_ids
list | cve_id
string | severity
string | cvss_score
float64 | repo_name
string | func_name
string | file_path
string | commit_hash
string | is_vulnerable
int64 |
|---|---|---|---|---|---|---|---|---|---|---|---|
Analyze the following code function for security vulnerabilities
|
@RequiresPermission(MANAGE_FINGERPRINT)
public void enroll(byte [] token, CancellationSignal cancel, int flags,
int userId, EnrollmentCallback callback) {
if (userId == UserHandle.USER_CURRENT) {
userId = getCurrentUserId();
}
if (callback == null) {
throw new IllegalArgumentException("Must supply an enrollment callback");
}
if (cancel != null) {
if (cancel.isCanceled()) {
Log.w(TAG, "enrollment already canceled");
return;
} else {
cancel.setOnCancelListener(new OnEnrollCancelListener());
}
}
if (mService != null) try {
mEnrollmentCallback = callback;
mService.enroll(mToken, token, userId, mServiceReceiver, flags,
mContext.getOpPackageName());
} catch (RemoteException e) {
Log.w(TAG, "Remote exception in enroll: ", e);
if (callback != null) {
// Though this may not be a hardware issue, it will cause apps to give up or try
// again later.
callback.onEnrollmentError(FINGERPRINT_ERROR_HW_UNAVAILABLE,
getErrorString(FINGERPRINT_ERROR_HW_UNAVAILABLE));
}
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: enroll
File: core/java/android/hardware/fingerprint/FingerprintManager.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-264"
] |
CVE-2016-3917
|
HIGH
| 7.2
|
android
|
enroll
|
core/java/android/hardware/fingerprint/FingerprintManager.java
|
f5334952131afa835dd3f08601fb3bced7b781cd
| 0
|
Analyze the following code function for security vulnerabilities
|
private ResourceReference computeResourceReference(String rawReference)
{
ResourceReference reference;
// Do we have a valid URL?
Matcher matcher = URL_SCHEME_PATTERN.matcher(rawReference);
if (matcher.lookingAt()) {
// We have UC1
reference = new ResourceReference(rawReference, ResourceType.URL);
} else if (rawReference.startsWith(MAILTO_PREFIX)) {
// We have UC2
reference = new ResourceReference(rawReference.substring(MAILTO_PREFIX.length()), ResourceType.MAILTO);
} else {
// We have UC3
reference = new ResourceReference(rawReference, ResourceType.PATH);
}
return reference;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: computeResourceReference
File: xwiki-rendering-syntaxes/xwiki-rendering-syntax-xhtml/src/main/java/org/xwiki/rendering/internal/parser/xhtml/wikimodel/XHTMLXWikiGeneratorListener.java
Repository: xwiki/xwiki-rendering
The code follows secure coding practices.
|
[
"CWE-79"
] |
CVE-2023-32070
|
MEDIUM
| 6.1
|
xwiki/xwiki-rendering
|
computeResourceReference
|
xwiki-rendering-syntaxes/xwiki-rendering-syntax-xhtml/src/main/java/org/xwiki/rendering/internal/parser/xhtml/wikimodel/XHTMLXWikiGeneratorListener.java
|
c40e2f5f9482ec6c3e71dbf1fff5ba8a5e44cdc1
| 0
|
Analyze the following code function for security vulnerabilities
|
public static byte[] getStreamBytes(PRStream stream) throws IOException {
RandomAccessFileOrArray rf = stream.getReader().getSafeFile();
try {
rf.reOpen();
return getStreamBytes(stream, rf);
}
finally {
try{rf.close();}catch(Exception e){}
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getStreamBytes
File: java/com/gitlab/pdftk_java/com/lowagie/text/pdf/PdfReader.java
Repository: pdftk-java/pdftk
The code follows secure coding practices.
|
[
"CWE-835"
] |
CVE-2021-37819
|
HIGH
| 7.5
|
pdftk-java/pdftk
|
getStreamBytes
|
java/com/gitlab/pdftk_java/com/lowagie/text/pdf/PdfReader.java
|
9b0cbb76c8434a8505f02ada02a94263dcae9247
| 0
|
Analyze the following code function for security vulnerabilities
|
public Class getItemType() {
if(itemType==null)
itemType = computeItemType();
return itemType;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getItemType
File: core/src/main/java/hudson/model/Descriptor.java
Repository: jenkinsci/jenkins
The code follows secure coding practices.
|
[
"CWE-264"
] |
CVE-2013-7330
|
MEDIUM
| 4
|
jenkinsci/jenkins
|
getItemType
|
core/src/main/java/hudson/model/Descriptor.java
|
36342d71e29e0620f803a7470ce96c61761648d8
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public List<String> getAutoRevokeExemptionRequestedPackages(int userId) {
return getPackagesWithAutoRevokePolicy(AUTO_REVOKE_DISCOURAGED, userId);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getAutoRevokeExemptionRequestedPackages
File: services/core/java/com/android/server/pm/permission/PermissionManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-281"
] |
CVE-2023-21249
|
MEDIUM
| 5.5
|
android
|
getAutoRevokeExemptionRequestedPackages
|
services/core/java/com/android/server/pm/permission/PermissionManagerService.java
|
c00b7e7dbc1fa30339adef693d02a51254755d7f
| 0
|
Analyze the following code function for security vulnerabilities
|
public String getLaunchedFromPackage(IBinder activityToken) throws RemoteException;
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getLaunchedFromPackage
File: core/java/android/app/IActivityManager.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-264"
] |
CVE-2016-3832
|
HIGH
| 8.3
|
android
|
getLaunchedFromPackage
|
core/java/android/app/IActivityManager.java
|
e7cf91a198de995c7440b3b64352effd2e309906
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public NumberType getNumberType() throws IOException
{
if (_numTypesValid == NR_UNKNOWN) {
_checkNumericValue(NR_UNKNOWN); // will also check event type
}
if (_currToken == JsonToken.VALUE_NUMBER_INT) {
if ((_numTypesValid & NR_INT) != 0) {
return NumberType.INT;
}
if ((_numTypesValid & NR_LONG) != 0) {
return NumberType.LONG;
}
return NumberType.BIG_INTEGER;
}
/* And then floating point types. Here optimal type
* needs to be big decimal, to avoid losing any data?
* However... using BD is slow, so let's allow returning
* double as type if no explicit call has been made to access
* data as BD?
*/
if ((_numTypesValid & NR_BIGDECIMAL) != 0) {
return NumberType.BIG_DECIMAL;
}
if ((_numTypesValid & NR_DOUBLE) != 0) {
return NumberType.DOUBLE;
}
return NumberType.FLOAT;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getNumberType
File: cbor/src/main/java/com/fasterxml/jackson/dataformat/cbor/CBORParser.java
Repository: FasterXML/jackson-dataformats-binary
The code follows secure coding practices.
|
[
"CWE-770"
] |
CVE-2020-28491
|
MEDIUM
| 5
|
FasterXML/jackson-dataformats-binary
|
getNumberType
|
cbor/src/main/java/com/fasterxml/jackson/dataformat/cbor/CBORParser.java
|
de072d314af8f5f269c8abec6930652af67bc8e6
| 0
|
Analyze the following code function for security vulnerabilities
|
private void doHandleAs(Subject subject, final HttpExchange pHttpExchange) {
try {
Subject.doAs(subject, new PrivilegedExceptionAction<Void>() {
public Void run() throws IOException {
doHandle(pHttpExchange);
return null;
}
});
} catch (PrivilegedActionException e) {
throw new SecurityException("Security exception: " + e.getCause(),e.getCause());
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: doHandleAs
File: agent/jvm/src/main/java/org/jolokia/jvmagent/handler/JolokiaHttpHandler.java
Repository: jolokia
The code follows secure coding practices.
|
[
"CWE-79"
] |
CVE-2018-1000129
|
MEDIUM
| 4.3
|
jolokia
|
doHandleAs
|
agent/jvm/src/main/java/org/jolokia/jvmagent/handler/JolokiaHttpHandler.java
|
5895d5c137c335e6b473e9dcb9baf748851bbc5f
| 0
|
Analyze the following code function for security vulnerabilities
|
private Properties constructLdapContextEnvironment(String namingProviderURL, String principalDN, Object credential, String authentication)
{
Properties env = createBaseProperties();
// Set defaults for key values if they are missing
String factoryName = env.getProperty(Context.INITIAL_CONTEXT_FACTORY);
if (factoryName == null)
{
factoryName = DEFAULT_LDAP_CTX_FACTORY;
env.setProperty(Context.INITIAL_CONTEXT_FACTORY, factoryName);
}
// If this method is called with an authentication type then use that.
if (authentication != null && authentication.length() > 0)
{
env.setProperty(Context.SECURITY_AUTHENTICATION, authentication);
}
else
{
String authType = env.getProperty(Context.SECURITY_AUTHENTICATION);
if (authType == null)
env.setProperty(Context.SECURITY_AUTHENTICATION, AUTH_TYPE_SIMPLE);
}
String providerURL = null;
if (namingProviderURL != null)
{
providerURL = namingProviderURL;
}
else
{
providerURL = (String) options.get(Context.PROVIDER_URL);
}
String protocol = env.getProperty(Context.SECURITY_PROTOCOL);
if (providerURL == null)
{
if (PROTOCOL_SSL.equals(protocol))
{
providerURL = DEFAULT_SSL_URL;
}
else
{
providerURL = DEFAULT_URL;
}
}
env.setProperty(Context.PROVIDER_URL, providerURL);
// Assume the caller of this method has checked the requirements for the principal and
// credentials.
if (principalDN != null)
env.setProperty(Context.SECURITY_PRINCIPAL, principalDN);
if (credential != null)
env.put(Context.SECURITY_CREDENTIALS, credential);
traceLdapEnv(env);
return env;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: constructLdapContextEnvironment
File: jboss-negotiation-extras/src/main/java/org/jboss/security/negotiation/AdvancedLdapLoginModule.java
Repository: wildfly-security/jboss-negotiation
The code follows secure coding practices.
|
[
"CWE-200"
] |
CVE-2015-1849
|
MEDIUM
| 4.3
|
wildfly-security/jboss-negotiation
|
constructLdapContextEnvironment
|
jboss-negotiation-extras/src/main/java/org/jboss/security/negotiation/AdvancedLdapLoginModule.java
|
0dc9d191b6eb1d13b8f0189c5b02ba6576f4722e
| 0
|
Analyze the following code function for security vulnerabilities
|
void showMenu(int menuState, Rect stackBounds, boolean allowMenuTimeout,
boolean resizeMenuOnShow, boolean withDelay, boolean showResizeHandle) {
mAllowMenuTimeout = allowMenuTimeout;
mDidLastShowMenuResize = resizeMenuOnShow;
final boolean enableEnterSplit =
mContext.getResources().getBoolean(R.bool.config_pipEnableEnterSplitButton);
if (mMenuState != menuState) {
// Disallow touches if the menu needs to resize while showing, and we are transitioning
// to/from a full menu state.
boolean disallowTouchesUntilAnimationEnd = resizeMenuOnShow
&& (mMenuState == MENU_STATE_FULL || menuState == MENU_STATE_FULL);
mAllowTouches = !disallowTouchesUntilAnimationEnd;
cancelDelayedHide();
if (mMenuContainerAnimator != null) {
mMenuContainerAnimator.cancel();
}
mMenuContainerAnimator = new AnimatorSet();
ObjectAnimator menuAnim = ObjectAnimator.ofFloat(mMenuContainer, View.ALPHA,
mMenuContainer.getAlpha(), 1f);
menuAnim.addUpdateListener(mMenuBgUpdateListener);
ObjectAnimator settingsAnim = ObjectAnimator.ofFloat(mSettingsButton, View.ALPHA,
mSettingsButton.getAlpha(), 1f);
ObjectAnimator dismissAnim = ObjectAnimator.ofFloat(mDismissButton, View.ALPHA,
mDismissButton.getAlpha(), 1f);
ObjectAnimator enterSplitAnim = ObjectAnimator.ofFloat(mEnterSplitButton, View.ALPHA,
mEnterSplitButton.getAlpha(),
enableEnterSplit && mFocusedTaskAllowSplitScreen ? 1f : 0f);
if (menuState == MENU_STATE_FULL) {
mMenuContainerAnimator.playTogether(menuAnim, settingsAnim, dismissAnim,
enterSplitAnim);
} else {
mMenuContainerAnimator.playTogether(enterSplitAnim);
}
mMenuContainerAnimator.setInterpolator(Interpolators.ALPHA_IN);
mMenuContainerAnimator.setDuration(ANIMATION_HIDE_DURATION_MS);
mMenuContainerAnimator.addListener(new AnimatorListenerAdapter() {
@Override
public void onAnimationEnd(Animator animation) {
mAllowTouches = true;
notifyMenuStateChangeFinish(menuState);
if (allowMenuTimeout) {
repostDelayedHide(INITIAL_DISMISS_DELAY);
}
}
@Override
public void onAnimationCancel(Animator animation) {
mAllowTouches = true;
}
});
if (withDelay) {
// starts the menu container animation after window expansion is completed
notifyMenuStateChangeStart(menuState, resizeMenuOnShow, () -> {
if (mMenuContainerAnimator == null) {
return;
}
mMenuContainerAnimator.setStartDelay(MENU_SHOW_ON_EXPAND_START_DELAY);
setVisibility(VISIBLE);
mMenuContainerAnimator.start();
});
} else {
notifyMenuStateChangeStart(menuState, resizeMenuOnShow, null);
setVisibility(VISIBLE);
mMenuContainerAnimator.start();
}
updateActionViews(menuState, stackBounds);
} else {
// If we are already visible, then just start the delayed dismiss and unregister any
// existing input consumers from the previous drag
if (allowMenuTimeout) {
repostDelayedHide(POST_INTERACTION_DISMISS_DELAY);
}
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: showMenu
File: libs/WindowManager/Shell/src/com/android/wm/shell/pip/phone/PipMenuView.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2023-40123
|
MEDIUM
| 5.5
|
android
|
showMenu
|
libs/WindowManager/Shell/src/com/android/wm/shell/pip/phone/PipMenuView.java
|
7212a4bec2d2f1a74fa54a12a04255d6a183baa9
| 0
|
Analyze the following code function for security vulnerabilities
|
public void setServiceFriendlyNames(Map<String, String> serviceFriendlyNames) {
mServiceFriendlyNames = serviceFriendlyNames;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: setServiceFriendlyNames
File: framework/java/android/net/wifi/hotspot2/PasspointConfiguration.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-120"
] |
CVE-2023-21243
|
MEDIUM
| 5.5
|
android
|
setServiceFriendlyNames
|
framework/java/android/net/wifi/hotspot2/PasspointConfiguration.java
|
5b49b8711efaadadf5052ba85288860c2d7ca7a6
| 0
|
Analyze the following code function for security vulnerabilities
|
void removeUriPermissionIfNeededLocked(UriPermission perm) {
if (perm.modeFlags == 0) {
final ArrayMap<GrantUri, UriPermission> perms = mGrantedUriPermissions.get(
perm.targetUid);
if (perms != null) {
if (DEBUG_URI_PERMISSION) Slog.v(TAG_URI_PERMISSION,
"Removing " + perm.targetUid + " permission to " + perm.uri);
perms.remove(perm.uri);
if (perms.isEmpty()) {
mGrantedUriPermissions.remove(perm.targetUid);
}
}
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: removeUriPermissionIfNeededLocked
File: services/core/java/com/android/server/am/ActivityManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-200"
] |
CVE-2016-2500
|
MEDIUM
| 4.3
|
android
|
removeUriPermissionIfNeededLocked
|
services/core/java/com/android/server/am/ActivityManagerService.java
|
9878bb99b77c3681f0fda116e2964bac26f349c3
| 0
|
Analyze the following code function for security vulnerabilities
|
@Test
public void saveTrans4(TestContext context) {
postgresClient = createFoo(context);
postgresClient.startTx(asyncAssertTx(context, trans -> {
postgresClient.save(trans, FOO, xPojo, context.asyncAssertSuccess(save -> {
String id = save;
postgresClient.endTx(trans, context.asyncAssertSuccess(end -> {
postgresClient.getById(FOO, id, context.asyncAssertSuccess(get -> {
context.assertEquals("x", get.getString("key"));
}));
}));
}));
}));
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: saveTrans4
File: domain-models-runtime/src/test/java/org/folio/rest/persist/PostgresClientIT.java
Repository: folio-org/raml-module-builder
The code follows secure coding practices.
|
[
"CWE-89"
] |
CVE-2019-15534
|
HIGH
| 7.5
|
folio-org/raml-module-builder
|
saveTrans4
|
domain-models-runtime/src/test/java/org/folio/rest/persist/PostgresClientIT.java
|
b7ef741133e57add40aa4cb19430a0065f378a94
| 0
|
Analyze the following code function for security vulnerabilities
|
private static void unimplemented(AsyncMethodCallback resultHandler) {
resultHandler.onError(new CentralDogmaException(ErrorCode.UNIMPLEMENTED));
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: unimplemented
File: server/src/main/java/com/linecorp/centraldogma/server/internal/thrift/CentralDogmaServiceImpl.java
Repository: line/centraldogma
The code follows secure coding practices.
|
[
"CWE-862"
] |
CVE-2021-38388
|
MEDIUM
| 6.5
|
line/centraldogma
|
unimplemented
|
server/src/main/java/com/linecorp/centraldogma/server/internal/thrift/CentralDogmaServiceImpl.java
|
e83b558ef9eaa44f71b7d9236bdec9f68c85b8bd
| 0
|
Analyze the following code function for security vulnerabilities
|
public boolean updateNetworkTransitionDisable(int networkId,
@WifiMonitor.TransitionDisableIndication int indicationBit) {
localLog("updateNetworkTransitionDisable: network ID=" + networkId
+ " indication: " + indicationBit);
WifiConfiguration config = getInternalConfiguredNetwork(networkId);
if (config == null) {
Log.e(TAG, "Cannot find network for " + networkId);
return false;
}
WifiConfiguration copy = new WifiConfiguration(config);
boolean changed = false;
if (0 != (indicationBit & WifiMonitor.TDI_USE_WPA3_PERSONAL)
&& config.isSecurityType(WifiConfiguration.SECURITY_TYPE_SAE)) {
config.setSecurityParamsEnabled(WifiConfiguration.SECURITY_TYPE_PSK, false);
changed = true;
}
if (0 != (indicationBit & WifiMonitor.TDI_USE_SAE_PK)) {
config.enableSaePkOnlyMode(true);
changed = true;
}
if (0 != (indicationBit & WifiMonitor.TDI_USE_WPA3_ENTERPRISE)
&& config.isSecurityType(WifiConfiguration.SECURITY_TYPE_EAP_WPA3_ENTERPRISE)) {
config.setSecurityParamsEnabled(WifiConfiguration.SECURITY_TYPE_EAP, false);
changed = true;
}
if (0 != (indicationBit & WifiMonitor.TDI_USE_ENHANCED_OPEN)
&& config.isSecurityType(WifiConfiguration.SECURITY_TYPE_OWE)) {
config.setSecurityParamsEnabled(WifiConfiguration.SECURITY_TYPE_OPEN, false);
changed = true;
}
if (changed) {
for (OnNetworkUpdateListener listener : mListeners) {
listener.onSecurityParamsUpdate(copy, config.getSecurityParamsList());
}
}
return true;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: updateNetworkTransitionDisable
File: service/java/com/android/server/wifi/WifiConfigManager.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2023-21242
|
CRITICAL
| 9.8
|
android
|
updateNetworkTransitionDisable
|
service/java/com/android/server/wifi/WifiConfigManager.java
|
72e903f258b5040b8f492cf18edd124b5a1ac770
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public final long skip(long n) throws IOException {
ensureOpen();
long pos = nativeAssetSeek(mAssetNativePtr, 0, 0);
if ((pos + n) > mLength) {
n = mLength - pos;
}
if (n > 0) {
nativeAssetSeek(mAssetNativePtr, n, 0);
}
return n;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: skip
File: core/java/android/content/res/AssetManager.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-415"
] |
CVE-2023-40103
|
HIGH
| 7.8
|
android
|
skip
|
core/java/android/content/res/AssetManager.java
|
c3bc12c484ef3bbca4cec19234437c45af5e584d
| 0
|
Analyze the following code function for security vulnerabilities
|
public boolean isRegisteredAttributionSource(@NonNull AttributionSource source) {
try {
return mPermissionManager.isRegisteredAttributionSource(source.asState());
} catch (RemoteException e) {
e.rethrowFromSystemServer();
}
return false;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: isRegisteredAttributionSource
File: core/java/android/permission/PermissionManager.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-281"
] |
CVE-2023-21249
|
MEDIUM
| 5.5
|
android
|
isRegisteredAttributionSource
|
core/java/android/permission/PermissionManager.java
|
c00b7e7dbc1fa30339adef693d02a51254755d7f
| 0
|
Analyze the following code function for security vulnerabilities
|
@Test
public void executeNullConnection(TestContext context) throws Exception {
postgresClientNullConnection().execute("SELECT 1", context.asyncAssertFailure());
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: executeNullConnection
File: domain-models-runtime/src/test/java/org/folio/rest/persist/PostgresClientIT.java
Repository: folio-org/raml-module-builder
The code follows secure coding practices.
|
[
"CWE-89"
] |
CVE-2019-15534
|
HIGH
| 7.5
|
folio-org/raml-module-builder
|
executeNullConnection
|
domain-models-runtime/src/test/java/org/folio/rest/persist/PostgresClientIT.java
|
b7ef741133e57add40aa4cb19430a0065f378a94
| 0
|
Analyze the following code function for security vulnerabilities
|
public List<Procedure> getAllSimpleFunctionAndProcedure() {
return jdbcTemplate.query(
GET_ALL_SIMPLE_FUNCTION_AND_PROCEDURE,
(resultSet, i) -> new Procedure.Builder()
.objectName("")
.procedureName(resultSet.getString("object_name"))
.overload(resultSet.getString("overload") == null ? "" : resultSet.getString("overload"))
.methodType(resultSet.getInt("proc_or_func") == 0 ? "PROCEDURE" : "FUNCTION")
.argumentList(getProcedureArguments("",
resultSet.getString("object_name"),
resultSet.getString("overload")))
.build()
);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getAllSimpleFunctionAndProcedure
File: obridge-main/src/main/java/org/obridge/dao/ProcedureDao.java
Repository: karsany/obridge
The code follows secure coding practices.
|
[
"CWE-89"
] |
CVE-2018-25075
|
MEDIUM
| 4
|
karsany/obridge
|
getAllSimpleFunctionAndProcedure
|
obridge-main/src/main/java/org/obridge/dao/ProcedureDao.java
|
52eca4ad05f3c292aed3178b2f58977686ffa376
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public boolean supportsSelfRegistration() {
return false;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: supportsSelfRegistration
File: portofino-core/src/main/java/com/manydesigns/portofino/shiro/AbstractPortofinoRealm.java
Repository: ManyDesigns/Portofino
The code follows secure coding practices.
|
[
"CWE-347"
] |
CVE-2021-29451
|
MEDIUM
| 6.4
|
ManyDesigns/Portofino
|
supportsSelfRegistration
|
portofino-core/src/main/java/com/manydesigns/portofino/shiro/AbstractPortofinoRealm.java
|
8c754a0ad234555e813dcbf9e57d637f9f23d8fb
| 0
|
Analyze the following code function for security vulnerabilities
|
private void newRevisionPicker(@Nullable AjaxRequestTarget target) {
String revision = state.blobIdent.revision;
boolean canCreateRef;
if (revision == null) {
revision = "master";
canCreateRef = false;
} else {
canCreateRef = true;
}
Component revisionPicker = new RevisionPicker(REVISION_PICKER_ID, projectModel, revision, canCreateRef) {
@Override
protected void onComponentTag(ComponentTag tag) {
super.onComponentTag(tag);
if (isOnBranch())
tag.put("title", "Press 'y' to get permalink");
}
@Override
protected String getRevisionUrl(String revision) {
BlobIdent blobIdent = new BlobIdent(revision, null, FileMode.TREE.getBits());
State state = new State(blobIdent);
PageParameters params = ProjectBlobPage.paramsOf(projectModel.getObject(), state);
return urlFor(ProjectBlobPage.class, params).toString();
}
@Override
protected void onSelect(AjaxRequestTarget target, String revision) {
BlobIdent newBlobIdent = new BlobIdent(state.blobIdent);
newBlobIdent.revision = revision;
if (newBlobIdent.path != null) {
try (RevWalk revWalk = new RevWalk(getProject().getRepository())) {
RevTree revTree = getProject().getRevCommit(revision, true).getTree();
TreeWalk treeWalk = TreeWalk.forPath(getProject().getRepository(), newBlobIdent.path, revTree);
if (treeWalk != null) {
newBlobIdent.mode = treeWalk.getRawMode(0);
} else {
newBlobIdent.path = null;
newBlobIdent.mode = FileMode.TREE.getBits();
}
} catch (IOException e) {
throw new RuntimeException(e);
}
}
ProjectBlobPage.this.onSelect(target, newBlobIdent, null);
}
};
if (target != null) {
replace(revisionPicker);
target.add(revisionPicker);
} else {
add(revisionPicker);
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: newRevisionPicker
File: server-core/src/main/java/io/onedev/server/web/page/project/blob/ProjectBlobPage.java
Repository: theonedev/onedev
The code follows secure coding practices.
|
[
"CWE-434"
] |
CVE-2021-21245
|
HIGH
| 7.5
|
theonedev/onedev
|
newRevisionPicker
|
server-core/src/main/java/io/onedev/server/web/page/project/blob/ProjectBlobPage.java
|
0c060153fb97c0288a1917efdb17cc426934dacb
| 0
|
Analyze the following code function for security vulnerabilities
|
public String getSpaceFilteredQuery(HttpServletRequest req) {
Profile authUser = getAuthUser(req);
String currentSpace = getSpaceIdFromCookie(authUser, req);
return getSpaceFilteredQuery(authUser, currentSpace);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getSpaceFilteredQuery
File: src/main/java/com/erudika/scoold/utils/ScooldUtils.java
Repository: Erudika/scoold
The code follows secure coding practices.
|
[
"CWE-130"
] |
CVE-2022-1543
|
MEDIUM
| 6.5
|
Erudika/scoold
|
getSpaceFilteredQuery
|
src/main/java/com/erudika/scoold/utils/ScooldUtils.java
|
62a0e92e1486ddc17676a7ead2c07ff653d167ce
| 0
|
Analyze the following code function for security vulnerabilities
|
public boolean isEnableCompression() {
return enableCompression;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: isEnableCompression
File: hazelcast/src/main/java/com/hazelcast/config/SerializationConfig.java
Repository: hazelcast
The code follows secure coding practices.
|
[
"CWE-502"
] |
CVE-2016-10750
|
MEDIUM
| 6.8
|
hazelcast
|
isEnableCompression
|
hazelcast/src/main/java/com/hazelcast/config/SerializationConfig.java
|
c1c31359a1df953e79a9ca9b6c54b3cdbfef11e9
| 0
|
Analyze the following code function for security vulnerabilities
|
int keyAt(int index) {
return mPidMap.keyAt(index);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: keyAt
File: services/core/java/com/android/server/am/ActivityManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2023-21292
|
MEDIUM
| 5.5
|
android
|
keyAt
|
services/core/java/com/android/server/am/ActivityManagerService.java
|
d10b27e539f7bc91c2360d429b9d05f05274670d
| 0
|
Analyze the following code function for security vulnerabilities
|
@GuardedBy(anyOf = {"this", "mProcLock"})
final void setProcessTrackerStateLOSP(ProcessRecord proc, int memFactor) {
if (proc.getThread() != null) {
proc.mProfile.setProcessTrackerState(
proc.mState.getReportedProcState(), memFactor);
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: setProcessTrackerStateLOSP
File: services/core/java/com/android/server/am/ActivityManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2023-21292
|
MEDIUM
| 5.5
|
android
|
setProcessTrackerStateLOSP
|
services/core/java/com/android/server/am/ActivityManagerService.java
|
d10b27e539f7bc91c2360d429b9d05f05274670d
| 0
|
Analyze the following code function for security vulnerabilities
|
public ApiClient addDefaultHeader(String key, String value) {
defaultHeaderMap.put(key, value);
return this;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: addDefaultHeader
File: samples/client/petstore/java/okhttp-gson/src/main/java/org/openapitools/client/ApiClient.java
Repository: OpenAPITools/openapi-generator
The code follows secure coding practices.
|
[
"CWE-668"
] |
CVE-2021-21430
|
LOW
| 2.1
|
OpenAPITools/openapi-generator
|
addDefaultHeader
|
samples/client/petstore/java/okhttp-gson/src/main/java/org/openapitools/client/ApiClient.java
|
2c576483f26f85b3979c6948a131f585c237109a
| 0
|
Analyze the following code function for security vulnerabilities
|
public Set<T> getSelectedItems() {
return getSelectionModel().getSelectedItems();
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getSelectedItems
File: server/src/main/java/com/vaadin/ui/Grid.java
Repository: vaadin/framework
The code follows secure coding practices.
|
[
"CWE-79"
] |
CVE-2019-25028
|
MEDIUM
| 4.3
|
vaadin/framework
|
getSelectedItems
|
server/src/main/java/com/vaadin/ui/Grid.java
|
c40bed109c3723b38694ed160ea647fef5b28593
| 0
|
Analyze the following code function for security vulnerabilities
|
private void ellipsize(int start, int end, int line,
char[] dest, int destoff, TextUtils.TruncateAt method) {
int ellipsisCount = getEllipsisCount(line);
if (ellipsisCount == 0) {
return;
}
int ellipsisStart = getEllipsisStart(line);
int linestart = getLineStart(line);
for (int i = ellipsisStart; i < ellipsisStart + ellipsisCount; i++) {
char c;
if (i == ellipsisStart) {
c = getEllipsisChar(method); // ellipsis
} else {
c = '\uFEFF'; // 0-width space
}
int a = i + linestart;
if (a >= start && a < end) {
dest[destoff + a - start] = c;
}
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: ellipsize
File: core/java/android/text/Layout.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-20"
] |
CVE-2018-9452
|
MEDIUM
| 4.3
|
android
|
ellipsize
|
core/java/android/text/Layout.java
|
3b6f84b77c30ec0bab5147b0cffc192c86ba2634
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public void extendVerificationTimeout(int id, int verificationCodeAtTimeout,
long millisecondsToDelay) {
mContext.enforceCallingOrSelfPermission(
android.Manifest.permission.PACKAGE_VERIFICATION_AGENT,
"Only package verification agents can extend verification timeouts");
final PackageVerificationState state = mPendingVerification.get(id);
final PackageVerificationResponse response = new PackageVerificationResponse(
verificationCodeAtTimeout, Binder.getCallingUid());
if (millisecondsToDelay > PackageManager.MAXIMUM_VERIFICATION_TIMEOUT) {
millisecondsToDelay = PackageManager.MAXIMUM_VERIFICATION_TIMEOUT;
}
if (millisecondsToDelay < 0) {
millisecondsToDelay = 0;
}
if ((verificationCodeAtTimeout != PackageManager.VERIFICATION_ALLOW)
&& (verificationCodeAtTimeout != PackageManager.VERIFICATION_REJECT)) {
verificationCodeAtTimeout = PackageManager.VERIFICATION_REJECT;
}
if ((state != null) && !state.timeoutExtended()) {
state.extendTimeout();
final Message msg = mHandler.obtainMessage(PACKAGE_VERIFIED);
msg.arg1 = id;
msg.obj = response;
mHandler.sendMessageDelayed(msg, millisecondsToDelay);
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: extendVerificationTimeout
File: services/core/java/com/android/server/pm/PackageManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-119"
] |
CVE-2016-2497
|
HIGH
| 7.5
|
android
|
extendVerificationTimeout
|
services/core/java/com/android/server/pm/PackageManagerService.java
|
a75537b496e9df71c74c1d045ba5569631a16298
| 0
|
Analyze the following code function for security vulnerabilities
|
public List<List<ObjectDiff>> getClassDiff(XWikiDocument fromDoc, XWikiDocument toDoc, XWikiContext context)
{
List<List<ObjectDiff>> difflist = new ArrayList<List<ObjectDiff>>();
BaseClass oldClass = fromDoc.getXClass();
BaseClass newClass = toDoc.getXClass();
if ((newClass == null) && (oldClass == null)) {
return difflist;
}
List<ObjectDiff> dlist = newClass.getDiff(oldClass, context);
if (!dlist.isEmpty()) {
difflist.add(dlist);
}
return difflist;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getClassDiff
File: xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/doc/XWikiDocument.java
Repository: xwiki/xwiki-platform
The code follows secure coding practices.
|
[
"CWE-787"
] |
CVE-2023-26470
|
HIGH
| 7.5
|
xwiki/xwiki-platform
|
getClassDiff
|
xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/doc/XWikiDocument.java
|
db3d1c62fc5fb59fefcda3b86065d2d362f55164
| 0
|
Analyze the following code function for security vulnerabilities
|
private RemoteViews minimallyDecoratedContentView(@NonNull RemoteViews customContent) {
StandardTemplateParams p = mParams.reset()
.viewType(StandardTemplateParams.VIEW_TYPE_NORMAL)
.decorationType(StandardTemplateParams.DECORATION_MINIMAL)
.fillTextsFrom(this);
TemplateBindResult result = new TemplateBindResult();
RemoteViews standard = applyStandardTemplate(getBaseLayoutResource(), p, result);
buildCustomContentIntoTemplate(mContext, standard, customContent,
p, result);
return standard;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: minimallyDecoratedContentView
File: core/java/android/app/Notification.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-862"
] |
CVE-2023-21288
|
MEDIUM
| 5.5
|
android
|
minimallyDecoratedContentView
|
core/java/android/app/Notification.java
|
726247f4f53e8cc0746175265652fa415a123c0c
| 0
|
Analyze the following code function for security vulnerabilities
|
public ImportResponse importSPApplication(ServiceProvider serviceProvider, String tenantDomain, String username,
boolean isUpdate) throws IdentityApplicationManagementException {
if (log.isDebugEnabled()) {
log.debug("Importing service provider from object " + serviceProvider.getApplicationName());
}
ImportResponse importResponse = importApplication(serviceProvider, tenantDomain, username, isUpdate);
if (log.isDebugEnabled()) {
log.debug(String.format("Service provider %s@%s created successfully from object",
serviceProvider.getApplicationName(), tenantDomain));
}
return importResponse;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: importSPApplication
File: components/application-mgt/org.wso2.carbon.identity.application.mgt/src/main/java/org/wso2/carbon/identity/application/mgt/ApplicationManagementServiceImpl.java
Repository: wso2/carbon-identity-framework
The code follows secure coding practices.
|
[
"CWE-611"
] |
CVE-2021-42646
|
MEDIUM
| 6.4
|
wso2/carbon-identity-framework
|
importSPApplication
|
components/application-mgt/org.wso2.carbon.identity.application.mgt/src/main/java/org/wso2/carbon/identity/application/mgt/ApplicationManagementServiceImpl.java
|
e9119883ee02a884f3c76c7bbc4022a4f4c58fc0
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public <T> int remove(Class<T> type) {
final String canonicalName = type.getCanonicalName();
final WriteResult<ClusterConfig, String> result = dbCollection.remove(DBQuery.is("type", canonicalName));
return result.getN();
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: remove
File: graylog2-server/src/main/java/org/graylog2/cluster/ClusterConfigServiceImpl.java
Repository: Graylog2/graylog2-server
The code follows secure coding practices.
|
[
"CWE-863"
] |
CVE-2024-24824
|
HIGH
| 8.8
|
Graylog2/graylog2-server
|
remove
|
graylog2-server/src/main/java/org/graylog2/cluster/ClusterConfigServiceImpl.java
|
75ef2b8d60e7d67f859b79fe712c8ae7b2e861d8
| 0
|
Analyze the following code function for security vulnerabilities
|
private int runGetInstallLocation() {
try {
int loc = mPm.getInstallLocation();
String locStr = "invalid";
if (loc == PackageHelper.APP_INSTALL_AUTO) {
locStr = "auto";
} else if (loc == PackageHelper.APP_INSTALL_INTERNAL) {
locStr = "internal";
} else if (loc == PackageHelper.APP_INSTALL_EXTERNAL) {
locStr = "external";
}
System.out.println(loc + "[" + locStr + "]");
return 0;
} catch (RemoteException e) {
System.err.println(e.toString());
System.err.println(PM_NOT_RUNNING_ERR);
return 1;
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: runGetInstallLocation
File: cmds/pm/src/com/android/commands/pm/Pm.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-264"
] |
CVE-2016-3833
|
HIGH
| 9.3
|
android
|
runGetInstallLocation
|
cmds/pm/src/com/android/commands/pm/Pm.java
|
4e4743a354e26467318b437892a9980eb9b8328a
| 0
|
Analyze the following code function for security vulnerabilities
|
public boolean yieldIfContendedSafely() {
return yieldIfContendedHelper(true /* check yielding */, -1 /* sleepAfterYieldDelay*/);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: yieldIfContendedSafely
File: core/java/android/database/sqlite/SQLiteDatabase.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-89"
] |
CVE-2018-9493
|
LOW
| 2.1
|
android
|
yieldIfContendedSafely
|
core/java/android/database/sqlite/SQLiteDatabase.java
|
ebc250d16c747f4161167b5ff58b3aea88b37acf
| 0
|
Analyze the following code function for security vulnerabilities
|
@RequiresPermission(value = MANAGE_DEVICE_POLICY_COMMON_CRITERIA_MODE, conditional = true)
public void setCommonCriteriaModeEnabled(@Nullable ComponentName admin, boolean enabled) {
throwIfParentInstance("setCommonCriteriaModeEnabled");
if (mService != null) {
try {
mService.setCommonCriteriaModeEnabled(admin, mContext.getPackageName(), enabled);
} catch (RemoteException e) {
throw e.rethrowFromSystemServer();
}
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: setCommonCriteriaModeEnabled
File: core/java/android/app/admin/DevicePolicyManager.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-862"
] |
CVE-2023-40089
|
HIGH
| 7.8
|
android
|
setCommonCriteriaModeEnabled
|
core/java/android/app/admin/DevicePolicyManager.java
|
e2e05f488da6abc765a62e7faf10cb74e729732e
| 0
|
Analyze the following code function for security vulnerabilities
|
public void setCarrierMerged(boolean isCarrierMerged) {
mIsCarrierMerged = isCarrierMerged;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: setCarrierMerged
File: framework/java/android/net/wifi/hotspot2/PasspointConfiguration.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-120"
] |
CVE-2023-21243
|
MEDIUM
| 5.5
|
android
|
setCarrierMerged
|
framework/java/android/net/wifi/hotspot2/PasspointConfiguration.java
|
5b49b8711efaadadf5052ba85288860c2d7ca7a6
| 0
|
Analyze the following code function for security vulnerabilities
|
public void updateSaveUi() {
if (mSave != null) {
mSave.setEnabled((isDraftDirty() && !isBlank()));
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: updateSaveUi
File: src/com/android/mail/compose/ComposeActivity.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-200"
] |
CVE-2016-2425
|
MEDIUM
| 4.3
|
android
|
updateSaveUi
|
src/com/android/mail/compose/ComposeActivity.java
|
0d9dfd649bae9c181e3afc5d571903f1eb5dc46f
| 0
|
Analyze the following code function for security vulnerabilities
|
public static synchronized void configure(String accessToken, ArtemisSecurityConfiguration configuration) {
INSTANCE.checkAccess(accessToken);
INSTANCE.configuration = configuration;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: configure
File: src/main/java/de/tum/in/test/api/security/ArtemisSecurityManager.java
Repository: ls1intum/Ares
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2024-23683
|
HIGH
| 8.2
|
ls1intum/Ares
|
configure
|
src/main/java/de/tum/in/test/api/security/ArtemisSecurityManager.java
|
af4f28a56e2fe600d8750b3b415352a0a3217392
| 0
|
Analyze the following code function for security vulnerabilities
|
@VisibleForTesting
public static GateKeeperResponse createGenericResponse(int responseCode) {
return new GateKeeperResponse(responseCode);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: createGenericResponse
File: core/java/android/service/gatekeeper/GateKeeperResponse.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-502"
] |
CVE-2017-0806
|
HIGH
| 9.3
|
android
|
createGenericResponse
|
core/java/android/service/gatekeeper/GateKeeperResponse.java
|
b87c968e5a41a1a09166199bf54eee12608f3900
| 0
|
Analyze the following code function for security vulnerabilities
|
public synchronized void shutdown() {
if (DESTROYED_UPDATER.compareAndSet(this, 0, 1)) {
engineMap.remove(ssl);
SSL.freeSSL(ssl);
SSL.freeBIO(networkBIO);
ssl = networkBIO = 0;
// internal errors can cause shutdown without marking the engine closed
isInboundDone = isOutboundDone = engineClosed = true;
}
// On shutdown clear all errors
SSL.clearError();
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: shutdown
File: handler/src/main/java/io/netty/handler/ssl/OpenSslEngine.java
Repository: netty
The code follows secure coding practices.
|
[
"CWE-835"
] |
CVE-2016-4970
|
HIGH
| 7.8
|
netty
|
shutdown
|
handler/src/main/java/io/netty/handler/ssl/OpenSslEngine.java
|
bc8291c80912a39fbd2303e18476d15751af0bf1
| 0
|
Analyze the following code function for security vulnerabilities
|
private void deleteItem(Context c, Item myitem) throws Exception
{
if (!isTest)
{
Collection[] collections = myitem.getCollections();
// Remove item from all the collections it's in
for (int i = 0; i < collections.length; i++)
{
collections[i].removeItem(myitem);
}
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: deleteItem
File: dspace-api/src/main/java/org/dspace/app/itemimport/ItemImport.java
Repository: DSpace
The code follows secure coding practices.
|
[
"CWE-22"
] |
CVE-2022-31195
|
HIGH
| 7.2
|
DSpace
|
deleteItem
|
dspace-api/src/main/java/org/dspace/app/itemimport/ItemImport.java
|
56e76049185bbd87c994128a9d77735ad7af0199
| 0
|
Analyze the following code function for security vulnerabilities
|
private void _readArray () throws JsonParseException
{
final IJsonParsePosition aStartPos = _getCurrentParsePos ();
m_aCallback.onArrayStart ();
int nIndex = 0;
while (true)
{
_skipSpaces ();
// Check for empty array
int c = _readChar ();
if (c == CJson.ARRAY_END)
{
if (nIndex != 0)
throw _parseEx (aStartPos, "Expected another element in JSON Array");
break;
}
_backupChar (c);
_readValue ();
_skipSpaces ();
c = _readChar ();
if (c == CJson.ITEM_SEPARATOR)
{
++nIndex;
m_aCallback.onArrayNextElement ();
continue;
}
if (c == CJson.ARRAY_END)
break;
throw _parseEx (aStartPos, "Unexpected character " + _getPrintableChar (c) + " in JSON array");
}
m_aCallback.onArrayEnd ();
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: _readArray
File: ph-json/src/main/java/com/helger/json/parser/JsonParser.java
Repository: phax/ph-commons
The code follows secure coding practices.
|
[
"CWE-787"
] |
CVE-2023-34612
|
HIGH
| 7.5
|
phax/ph-commons
|
_readArray
|
ph-json/src/main/java/com/helger/json/parser/JsonParser.java
|
02a4d034dcfb2b6e1796b25f519bf57a6796edce
| 0
|
Analyze the following code function for security vulnerabilities
|
public void updateKeyguardPosition(float x) {
mView.updatePositionByTouchX(x);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: updateKeyguardPosition
File: packages/SystemUI/src/com/android/keyguard/KeyguardSecurityContainerController.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2023-21245
|
HIGH
| 7.8
|
android
|
updateKeyguardPosition
|
packages/SystemUI/src/com/android/keyguard/KeyguardSecurityContainerController.java
|
a33159e8cb297b9eee6fa5c63c0e343d05fad622
| 0
|
Analyze the following code function for security vulnerabilities
|
public Map<String, ResourceProvider> getResourceProviders() {
return resourceProviders;
}
|
Vulnerability Classification:
- CWE: CWE-22
- CVE: CVE-2020-24621
- Severity: MEDIUM
- CVSS Score: 6.5
Description: UIFR-215: Do not allow loading arbitrary files
Function: getResourceProviders
File: api/src/main/java/org/openmrs/ui/framework/resource/ResourceFactory.java
Repository: openmrs/openmrs-module-uiframework
Fixed Code:
public Map<String, ResourceProvider> getResourceProviders() {
return resourceProviders;
}
|
[
"CWE-22"
] |
CVE-2020-24621
|
MEDIUM
| 6.5
|
openmrs/openmrs-module-uiframework
|
getResourceProviders
|
api/src/main/java/org/openmrs/ui/framework/resource/ResourceFactory.java
|
0422fa52c7eba3d96cce2936cb92897dca4b680a
| 1
|
Analyze the following code function for security vulnerabilities
|
public void read(InputStream xarStream) throws IOException, XarException
{
ZipArchiveInputStream zis = new ZipArchiveInputStream(xarStream, "UTF-8", false);
try {
for (ZipArchiveEntry entry = zis.getNextZipEntry(); entry != null; entry = zis.getNextZipEntry()) {
if (!entry.isDirectory() && zis.canReadEntryData(entry)) {
readEntry(zis, entry.getName());
}
}
} finally {
zis.close();
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: read
File: xwiki-platform-core/xwiki-platform-xar/xwiki-platform-xar-model/src/main/java/org/xwiki/xar/XarPackage.java
Repository: xwiki/xwiki-platform
The code follows secure coding practices.
|
[
"CWE-611"
] |
CVE-2023-27480
|
HIGH
| 7.7
|
xwiki/xwiki-platform
|
read
|
xwiki-platform-core/xwiki-platform-xar/xwiki-platform-xar-model/src/main/java/org/xwiki/xar/XarPackage.java
|
e3527b98fdd8dc8179c24dc55e662b2c55199434
| 0
|
Analyze the following code function for security vulnerabilities
|
private void startCapture() {
if (captureBuffer==null) {
captureBuffer=new StringBuilder();
}
captureStart=index-1;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: startCapture
File: src/main/org/hjson/JsonParser.java
Repository: hjson/hjson-java
The code follows secure coding practices.
|
[
"CWE-787"
] |
CVE-2023-34620
|
HIGH
| 7.5
|
hjson/hjson-java
|
startCapture
|
src/main/org/hjson/JsonParser.java
|
91bef056d56bf968451887421c89a44af1d692ff
| 0
|
Analyze the following code function for security vulnerabilities
|
public PropertyDao getPropertyDao() {
return propertyDao;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getPropertyDao
File: server/src/test-shared/java/com/thoughtworks/go/server/dao/DatabaseAccessHelper.java
Repository: gocd
The code follows secure coding practices.
|
[
"CWE-697"
] |
CVE-2022-39308
|
MEDIUM
| 5.9
|
gocd
|
getPropertyDao
|
server/src/test-shared/java/com/thoughtworks/go/server/dao/DatabaseAccessHelper.java
|
236d4baf92e6607f2841c151c855adcc477238b8
| 0
|
Analyze the following code function for security vulnerabilities
|
public int getProtocolVersion() {
return protocolVersion.get();
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getProtocolVersion
File: activemq-broker/src/main/java/org/apache/activemq/broker/TransportConnection.java
Repository: apache/activemq
The code follows secure coding practices.
|
[
"CWE-264"
] |
CVE-2014-3576
|
MEDIUM
| 5
|
apache/activemq
|
getProtocolVersion
|
activemq-broker/src/main/java/org/apache/activemq/broker/TransportConnection.java
|
00921f2
| 0
|
Analyze the following code function for security vulnerabilities
|
@Test
public void parseQueryMTypeWExplicit() throws Exception {
HttpQuery query = NettyMocks.getQuery(tsdb,
"/api/query?start=1h-ago&m=sum:explicit_tags:sys.cpu.0{host=web01}");
TSQuery tsq = (TSQuery) parseQuery.invoke(rpc, tsdb, query, expressions);
TSSubQuery sub = tsq.getQueries().get(0);
assertNotNull(sub.getTags());
assertEquals("literal_or(web01)", sub.getTags().get("host"));
assertTrue(sub.getExplicitTags());
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: parseQueryMTypeWExplicit
File: test/tsd/TestQueryRpc.java
Repository: OpenTSDB/opentsdb
The code follows secure coding practices.
|
[
"CWE-79"
] |
CVE-2023-25827
|
MEDIUM
| 6.1
|
OpenTSDB/opentsdb
|
parseQueryMTypeWExplicit
|
test/tsd/TestQueryRpc.java
|
ff02c1e95e60528275f69b31bcbf7b2ac625cea8
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public boolean getCameraDisabled(ComponentName who, String callerPackageName, int userHandle,
boolean parent) {
if (!mHasFeature) {
return false;
}
CallerIdentity caller;
if (isPolicyEngineForFinanceFlagEnabled()) {
caller = getCallerIdentity(who, callerPackageName);
} else {
caller = getCallerIdentity(who);
}
if (isPolicyEngineForFinanceFlagEnabled()) {
Preconditions.checkCallAuthorization(
hasFullCrossUsersPermission(caller, userHandle)
|| isCameraServerUid(caller)
|| hasPermission(MANAGE_DEVICE_POLICY_CAMERA,
caller.getPackageName(), userHandle)
|| hasPermission(QUERY_ADMIN_POLICY, caller.getPackageName()));
} else {
Preconditions.checkCallAuthorization(
hasFullCrossUsersPermission(caller, userHandle) || isCameraServerUid(caller));
if (parent) {
Preconditions.checkCallAuthorization(
isProfileOwnerOfOrganizationOwnedDevice(caller.getUserId()));
}
}
int affectedUserId = parent ? getProfileParentId(userHandle) : userHandle;
if (isPolicyEngineForFinanceFlagEnabled()) {
PolicyDefinition<Boolean> policy =
PolicyDefinition.getPolicyDefinitionForUserRestriction(
UserManager.DISALLOW_CAMERA);
if (who != null) {
EnforcingAdmin admin = getEnforcingAdminForCaller(who, callerPackageName);
return Boolean.TRUE.equals(
mDevicePolicyEngine.getLocalPolicySetByAdmin(
policy, admin, affectedUserId));
} else {
return Boolean.TRUE.equals(
mDevicePolicyEngine.getResolvedPolicy(policy, affectedUserId));
}
} else {
synchronized (getLockObject()) {
if (who != null) {
ActiveAdmin admin = getActiveAdminUncheckedLocked(who, userHandle, parent);
return (admin != null) && admin.disableCamera;
}
// First, see if DO has set it. If so, it's device-wide.
final ActiveAdmin deviceOwner = getDeviceOwnerAdminLocked();
if (deviceOwner != null && deviceOwner.disableCamera) {
return true;
}
// Return the strictest policy across all participating admins.
List<ActiveAdmin> admins = getActiveAdminsForAffectedUserLocked(affectedUserId);
// Determine whether or not the device camera is disabled for any active admins.
for (ActiveAdmin activeAdmin : admins) {
if (activeAdmin.disableCamera) {
return true;
}
}
return false;
}
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getCameraDisabled
File: services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-862"
] |
CVE-2023-40089
|
HIGH
| 7.8
|
android
|
getCameraDisabled
|
services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
|
e2e05f488da6abc765a62e7faf10cb74e729732e
| 0
|
Analyze the following code function for security vulnerabilities
|
public boolean setPermittedAccessibilityServices(@NonNull ComponentName admin,
List<String> packageNames) {
throwIfParentInstance("setPermittedAccessibilityServices");
if (mService != null) {
try {
return mService.setPermittedAccessibilityServices(admin, packageNames);
} catch (RemoteException e) {
throw e.rethrowFromSystemServer();
}
}
return false;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: setPermittedAccessibilityServices
File: core/java/android/app/admin/DevicePolicyManager.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-862"
] |
CVE-2023-40089
|
HIGH
| 7.8
|
android
|
setPermittedAccessibilityServices
|
core/java/android/app/admin/DevicePolicyManager.java
|
e2e05f488da6abc765a62e7faf10cb74e729732e
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public void setPackageScreenCompatMode(String packageName, int mode) {
mAmInternal.enforceCallingPermission(android.Manifest.permission.SET_SCREEN_COMPATIBILITY,
"setPackageScreenCompatMode");
synchronized (mGlobalLock) {
mCompatModePackages.setPackageScreenCompatModeLocked(packageName, mode);
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: setPackageScreenCompatMode
File: services/core/java/com/android/server/wm/ActivityTaskManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-862"
] |
CVE-2023-40094
|
HIGH
| 7.8
|
android
|
setPackageScreenCompatMode
|
services/core/java/com/android/server/wm/ActivityTaskManagerService.java
|
1120bc7e511710b1b774adf29ba47106292365e7
| 0
|
Analyze the following code function for security vulnerabilities
|
protected B flushPreface(boolean flushPreface) {
this.flushPreface = flushPreface;
return self();
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: flushPreface
File: codec-http2/src/main/java/io/netty/handler/codec/http2/AbstractHttp2ConnectionHandlerBuilder.java
Repository: netty
The code follows secure coding practices.
|
[
"CWE-400"
] |
CVE-2023-44487
|
HIGH
| 7.5
|
netty
|
flushPreface
|
codec-http2/src/main/java/io/netty/handler/codec/http2/AbstractHttp2ConnectionHandlerBuilder.java
|
58f75f665aa81a8cbcf6ffa74820042a285c5e61
| 0
|
Analyze the following code function for security vulnerabilities
|
@Nullable
public String getFactoryMacAddress() {
MacAddress factoryMacAddress = retrieveFactoryMacAddressAndStoreIfNecessary();
if (factoryMacAddress != null) return factoryMacAddress.toString();
// For devices with older HAL's (version < 1.3), no API exists to retrieve factory MAC
// address (and also does not support MAC randomization - needs verson 1.2). So, just
// return the regular MAC address from the interface.
if (!mWifiGlobals.isConnectedMacRandomizationEnabled()) {
Log.w(TAG, "Can't get factory MAC address, return the MAC address");
return mWifiNative.getMacAddress(mInterfaceName);
}
return null;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getFactoryMacAddress
File: service/java/com/android/server/wifi/ClientModeImpl.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2023-21242
|
CRITICAL
| 9.8
|
android
|
getFactoryMacAddress
|
service/java/com/android/server/wifi/ClientModeImpl.java
|
72e903f258b5040b8f492cf18edd124b5a1ac770
| 0
|
Analyze the following code function for security vulnerabilities
|
private boolean isStkAppInstalled() {
Intent intent = new Intent(AppInterface.CAT_CMD_ACTION);
PackageManager pm = mContext.getPackageManager();
List<ResolveInfo> broadcastReceivers =
pm.queryBroadcastReceivers(intent, PackageManager.GET_META_DATA);
int numReceiver = broadcastReceivers == null ? 0 : broadcastReceivers.size();
return (numReceiver > 0);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: isStkAppInstalled
File: src/java/com/android/internal/telephony/cat/CatService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-264"
] |
CVE-2015-3843
|
HIGH
| 9.3
|
android
|
isStkAppInstalled
|
src/java/com/android/internal/telephony/cat/CatService.java
|
b48581401259439dc5ef6dcf8b0f303e4cbefbe9
| 0
|
Analyze the following code function for security vulnerabilities
|
public void notifyANQPDone(AnqpEvent anqpEvent) {
mPasspointEventHandler.notifyANQPDone(anqpEvent);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: notifyANQPDone
File: service/java/com/android/server/wifi/hotspot2/PasspointManager.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-120"
] |
CVE-2023-21243
|
MEDIUM
| 5.5
|
android
|
notifyANQPDone
|
service/java/com/android/server/wifi/hotspot2/PasspointManager.java
|
5b49b8711efaadadf5052ba85288860c2d7ca7a6
| 0
|
Analyze the following code function for security vulnerabilities
|
private OraclePackage getAllStandaloneProcedureAndFunction() {
OraclePackage oraclePackage = new OraclePackage();
oraclePackage.setName("PROCEDURES_AND_FUNCTIONS");
oraclePackage.setProcedureList(getAllSimpleFunctionAndProcedure());
return oraclePackage;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getAllStandaloneProcedureAndFunction
File: obridge-main/src/main/java/org/obridge/dao/ProcedureDao.java
Repository: karsany/obridge
The code follows secure coding practices.
|
[
"CWE-89"
] |
CVE-2018-25075
|
MEDIUM
| 4
|
karsany/obridge
|
getAllStandaloneProcedureAndFunction
|
obridge-main/src/main/java/org/obridge/dao/ProcedureDao.java
|
52eca4ad05f3c292aed3178b2f58977686ffa376
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public int compare(TaskRecord lhs, TaskRecord rhs) {
return rhs.taskId - lhs.taskId;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: compare
File: services/core/java/com/android/server/am/ActivityManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-284"
] |
CVE-2015-3833
|
MEDIUM
| 4.3
|
android
|
compare
|
services/core/java/com/android/server/am/ActivityManagerService.java
|
aaa0fee0d7a8da347a0c47cef5249c70efee209e
| 0
|
Analyze the following code function for security vulnerabilities
|
public boolean hasDlsQuery() {
return dlsQuery != null && !dlsQuery.isEmpty();
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: hasDlsQuery
File: src/main/java/org/opensearch/security/securityconf/ConfigModelV7.java
Repository: opensearch-project/security
The code follows secure coding practices.
|
[
"CWE-612",
"CWE-863"
] |
CVE-2022-41918
|
MEDIUM
| 6.3
|
opensearch-project/security
|
hasDlsQuery
|
src/main/java/org/opensearch/security/securityconf/ConfigModelV7.java
|
f7cc569c9d3fa5d5432c76c854eed280d45ce6f4
| 0
|
Analyze the following code function for security vulnerabilities
|
public void loadUrlAsync(final AwContents awContents,
final String url) throws Exception {
loadUrlAsync(awContents, url, null);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: loadUrlAsync
File: android_webview/javatests/src/org/chromium/android_webview/test/AwTestBase.java
Repository: chromium
The code follows secure coding practices.
|
[
"CWE-254"
] |
CVE-2016-5155
|
MEDIUM
| 4.3
|
chromium
|
loadUrlAsync
|
android_webview/javatests/src/org/chromium/android_webview/test/AwTestBase.java
|
b8dcfeb065bbfd777cdc5f5433da9a87f25e6ec6
| 0
|
Analyze the following code function for security vulnerabilities
|
private static LicenseInfo setIfValid(LicenseInfo value, LicenseInfo def) {
if (value.isValid() || def.isNone())
return value;
return def;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: setIfValid
File: src/net/sourceforge/plantuml/version/LicenseInfo.java
Repository: plantuml
The code follows secure coding practices.
|
[
"CWE-284"
] |
CVE-2023-3431
|
MEDIUM
| 5.3
|
plantuml
|
setIfValid
|
src/net/sourceforge/plantuml/version/LicenseInfo.java
|
fbe7fa3b25b4c887d83927cffb1009ec6cb8ab1e
| 0
|
Analyze the following code function for security vulnerabilities
|
protected ValueValidator<V> valueValidator() {
return valueValidator;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: valueValidator
File: codec/src/main/java/io/netty/handler/codec/DefaultHeaders.java
Repository: netty
The code follows secure coding practices.
|
[
"CWE-436",
"CWE-113"
] |
CVE-2022-41915
|
MEDIUM
| 6.5
|
netty
|
valueValidator
|
codec/src/main/java/io/netty/handler/codec/DefaultHeaders.java
|
fe18adff1c2b333acb135ab779a3b9ba3295a1c4
| 0
|
Analyze the following code function for security vulnerabilities
|
private void useHandler(Handler handler) {
if (handler != null) {
mHandler = new MyHandler(handler.getLooper());
} else if (mHandler.getLooper() != mContext.getMainLooper()){
mHandler = new MyHandler(mContext.getMainLooper());
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: useHandler
File: core/java/android/hardware/fingerprint/FingerprintManager.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-264"
] |
CVE-2016-3917
|
HIGH
| 7.2
|
android
|
useHandler
|
core/java/android/hardware/fingerprint/FingerprintManager.java
|
f5334952131afa835dd3f08601fb3bced7b781cd
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public List<String> searchDocumentsNames(String wheresql, int nb, int start, XWikiContext context)
throws XWikiException
{
return searchDocumentsNames(wheresql, nb, start, "", context);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: searchDocumentsNames
File: xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/store/XWikiHibernateStore.java
Repository: xwiki/xwiki-platform
The code follows secure coding practices.
|
[
"CWE-459"
] |
CVE-2023-36468
|
HIGH
| 8.8
|
xwiki/xwiki-platform
|
searchDocumentsNames
|
xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/store/XWikiHibernateStore.java
|
15a6f845d8206b0ae97f37aa092ca43d4f9d6e59
| 0
|
Analyze the following code function for security vulnerabilities
|
public void removeContentProvider(IBinder connection, boolean stable) {
enforceNotIsolatedCaller("removeContentProvider");
long ident = Binder.clearCallingIdentity();
try {
synchronized (this) {
ContentProviderConnection conn;
try {
conn = (ContentProviderConnection)connection;
} catch (ClassCastException e) {
String msg ="removeContentProvider: " + connection
+ " not a ContentProviderConnection";
Slog.w(TAG, msg);
throw new IllegalArgumentException(msg);
}
if (conn == null) {
throw new NullPointerException("connection is null");
}
if (decProviderCountLocked(conn, null, null, stable)) {
updateOomAdjLocked();
}
}
} finally {
Binder.restoreCallingIdentity(ident);
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: removeContentProvider
File: services/core/java/com/android/server/am/ActivityManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-863"
] |
CVE-2018-9492
|
HIGH
| 7.2
|
android
|
removeContentProvider
|
services/core/java/com/android/server/am/ActivityManagerService.java
|
962fb40991f15be4f688d960aa00073683ebdd20
| 0
|
Analyze the following code function for security vulnerabilities
|
public static @NonNull String bindList(@NonNull Object... args) {
final StringBuilder sb = new StringBuilder();
sb.append('(');
for (int i = 0; i < args.length; i++) {
sb.append('?');
if (i < args.length - 1) {
sb.append(',');
}
}
sb.append(')');
return DatabaseUtils.bindSelection(sb.toString(), args);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: bindList
File: src/com/android/providers/media/util/DatabaseUtils.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-89"
] |
CVE-2023-35683
|
MEDIUM
| 5.5
|
android
|
bindList
|
src/com/android/providers/media/util/DatabaseUtils.java
|
23d156ed1bed6d2c2b325f0be540d0afca510c49
| 0
|
Analyze the following code function for security vulnerabilities
|
public abstract String getConfiguredWidgetset(VaadinRequest request);
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getConfiguredWidgetset
File: server/src/main/java/com/vaadin/server/VaadinService.java
Repository: vaadin/framework
The code follows secure coding practices.
|
[
"CWE-203"
] |
CVE-2021-31403
|
LOW
| 1.9
|
vaadin/framework
|
getConfiguredWidgetset
|
server/src/main/java/com/vaadin/server/VaadinService.java
|
d852126ab6f0c43f937239305bd0e9594834fe34
| 0
|
Analyze the following code function for security vulnerabilities
|
private String stepIDFromSource(String source) {
if (source != null && source.length() > 0) {
// Strip leading # if it exists
if (source.charAt(0) == '#') {
source = source.substring(1);
}
// Draft 3/V1 notation is 'stepID/outputID'
int slashSplit = source.indexOf("/");
if (slashSplit != -1) {
source = source.substring(0, slashSplit);
} else {
// Draft 2 notation was 'stepID.outputID'
int dotSplit = source.indexOf(".");
if (dotSplit != -1) {
source = source.substring(0, dotSplit);
}
}
}
return source;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: stepIDFromSource
File: src/main/java/org/commonwl/view/cwl/CWLService.java
Repository: common-workflow-language/cwlviewer
The code follows secure coding practices.
|
[
"CWE-502"
] |
CVE-2021-41110
|
HIGH
| 7.5
|
common-workflow-language/cwlviewer
|
stepIDFromSource
|
src/main/java/org/commonwl/view/cwl/CWLService.java
|
f6066f09edb70033a2ce80200e9fa9e70a5c29de
| 0
|
Analyze the following code function for security vulnerabilities
|
public static String viewInfo(View v) {
return "[(" + v.getLeft() + "," + v.getTop() + ")(" + v.getRight() + "," + v.getBottom()
+ ") " + v.getWidth() + "x" + v.getHeight() + "]";
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: viewInfo
File: packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBar.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2017-0822
|
HIGH
| 7.5
|
android
|
viewInfo
|
packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBar.java
|
c574568aaede7f652432deb7707f20ae54bbdf9a
| 0
|
Analyze the following code function for security vulnerabilities
|
void onBootPhase(int phase) {
if (DEBUG || DEBUG_REBOOT) {
Slog.d(TAG, "onBootPhase: " + phase);
}
switch (phase) {
case SystemService.PHASE_LOCK_SETTINGS_READY:
initialize();
break;
case SystemService.PHASE_BOOT_COMPLETED:
mBootCompleted.set(true);
break;
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: onBootPhase
File: services/core/java/com/android/server/pm/ShortcutService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2023-40079
|
HIGH
| 7.8
|
android
|
onBootPhase
|
services/core/java/com/android/server/pm/ShortcutService.java
|
96e0524c48c6e58af7d15a2caf35082186fc8de2
| 0
|
Analyze the following code function for security vulnerabilities
|
private Deque<DocumentReference> getDocumentReferenceDeque()
{
ExecutionContext econtext = this.execution.getContext();
Deque<DocumentReference> documentReferenceStack =
(Deque<DocumentReference>) econtext.getProperty(DOCUMENT_REFERENCE_STACK_KEY);
if (documentReferenceStack == null) {
documentReferenceStack = new LinkedList<>();
econtext.newProperty(DOCUMENT_REFERENCE_STACK_KEY).inherited().initial(documentReferenceStack).declare();
}
return documentReferenceStack;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getDocumentReferenceDeque
File: xwiki-platform-core/xwiki-platform-display/xwiki-platform-display-api/src/main/java/org/xwiki/display/internal/AbstractDocumentTitleDisplayer.java
Repository: xwiki/xwiki-platform
The code follows secure coding practices.
|
[
"CWE-863"
] |
CVE-2023-46244
|
HIGH
| 8.8
|
xwiki/xwiki-platform
|
getDocumentReferenceDeque
|
xwiki-platform-core/xwiki-platform-display/xwiki-platform-display-api/src/main/java/org/xwiki/display/internal/AbstractDocumentTitleDisplayer.java
|
11a9170dfe63e59f4066db67f84dbfce4ed619c6
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public boolean isMember(final Context context, EPerson eperson, final String groupName) throws SQLException {
return isMember(context, eperson, findByName(context, groupName));
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: isMember
File: dspace-api/src/main/java/org/dspace/eperson/GroupServiceImpl.java
Repository: DSpace
The code follows secure coding practices.
|
[
"CWE-863"
] |
CVE-2021-41189
|
HIGH
| 9
|
DSpace
|
isMember
|
dspace-api/src/main/java/org/dspace/eperson/GroupServiceImpl.java
|
277b499a5cd3a4f5eb2370513a1b7e4ec2a6e041
| 0
|
Analyze the following code function for security vulnerabilities
|
public static Path getDataFolder(String pi, String dataFolderName, String dataRepositoryFolder) {
Path repository;
// TODO Find a way to use absolute repo paths in unit tests
if (StringUtils.isBlank(dataRepositoryFolder)) {
repository = Paths.get(DataManager.getInstance().getConfiguration().getViewerHome());
} else if (Paths.get(FileTools.adaptPathForWindows(dataRepositoryFolder)).isAbsolute()) {
repository = Paths.get(dataRepositoryFolder);
} else {
repository = Paths.get(DataManager.getInstance().getConfiguration().getDataRepositoriesHome(), dataRepositoryFolder);
}
Path folder = repository.resolve(dataFolderName).resolve(pi);
return folder;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getDataFolder
File: goobi-viewer-core/src/main/java/io/goobi/viewer/controller/DataFileTools.java
Repository: intranda/goobi-viewer-core
The code follows secure coding practices.
|
[
"CWE-22"
] |
CVE-2020-15124
|
MEDIUM
| 4
|
intranda/goobi-viewer-core
|
getDataFolder
|
goobi-viewer-core/src/main/java/io/goobi/viewer/controller/DataFileTools.java
|
44ceb8e2e7e888391e8a941127171d6366770df3
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public XMLBuilder2 root() {
return new XMLBuilder2(getDocument());
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: root
File: src/main/java/com/jamesmurty/utils/XMLBuilder2.java
Repository: jmurty/java-xmlbuilder
The code follows secure coding practices.
|
[
"CWE-611"
] |
CVE-2014-125087
|
MEDIUM
| 5.2
|
jmurty/java-xmlbuilder
|
root
|
src/main/java/com/jamesmurty/utils/XMLBuilder2.java
|
e6fddca201790abab4f2c274341c0bb8835c3e73
| 0
|
Analyze the following code function for security vulnerabilities
|
@Beta
@Deprecated
public final CredentialStore getCredentialStore() {
return credentialStore;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getCredentialStore
File: google-oauth-client/src/main/java/com/google/api/client/auth/oauth2/AuthorizationCodeFlow.java
Repository: googleapis/google-oauth-java-client
The code follows secure coding practices.
|
[
"CWE-863"
] |
CVE-2020-7692
|
MEDIUM
| 6.4
|
googleapis/google-oauth-java-client
|
getCredentialStore
|
google-oauth-client/src/main/java/com/google/api/client/auth/oauth2/AuthorizationCodeFlow.java
|
13433cd7dd06267fc261f0b1d4764f8e3432c824
| 0
|
Analyze the following code function for security vulnerabilities
|
public boolean isLocal() {
return getSeti().getOort().getURL().equals(getOortURL());
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: isLocal
File: cometd-java/cometd-java-oort/src/main/java/org/cometd/oort/Seti.java
Repository: cometd
The code follows secure coding practices.
|
[
"CWE-863"
] |
CVE-2022-24721
|
MEDIUM
| 5.5
|
cometd
|
isLocal
|
cometd-java/cometd-java-oort/src/main/java/org/cometd/oort/Seti.java
|
bb445a143fbf320f17c62e340455cd74acfb5929
| 0
|
Analyze the following code function for security vulnerabilities
|
public boolean isRecordLoaded() {
return viewManager != null;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: isRecordLoaded
File: goobi-viewer-core/src/main/java/io/goobi/viewer/managedbeans/ActiveDocumentBean.java
Repository: intranda/goobi-viewer-core
The code follows secure coding practices.
|
[
"CWE-79"
] |
CVE-2023-29014
|
MEDIUM
| 6.1
|
intranda/goobi-viewer-core
|
isRecordLoaded
|
goobi-viewer-core/src/main/java/io/goobi/viewer/managedbeans/ActiveDocumentBean.java
|
c29efe60e745a94d03debc17681c4950f3917455
| 0
|
Analyze the following code function for security vulnerabilities
|
public void acknowledgeAuthentication(String realm, Credential credential) {
// this notification is only used on the project-local store.
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: acknowledgeAuthentication
File: src/main/java/hudson/scm/SubversionSCM.java
Repository: jenkinsci/subversion-plugin
The code follows secure coding practices.
|
[
"CWE-255"
] |
CVE-2013-6372
|
LOW
| 2.1
|
jenkinsci/subversion-plugin
|
acknowledgeAuthentication
|
src/main/java/hudson/scm/SubversionSCM.java
|
7d4562d6f7e40de04bbe29577b51c79f07d05ba6
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public void onPackageUninstalled(String name, int userId) {
synchronized (mGlobalLock) {
mAppWarnings.onPackageUninstalled(name);
mCompatModePackages.handlePackageUninstalledLocked(name);
mPackageConfigPersister.onPackageUninstall(name, userId);
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: onPackageUninstalled
File: services/core/java/com/android/server/wm/ActivityTaskManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-862"
] |
CVE-2023-40094
|
HIGH
| 7.8
|
android
|
onPackageUninstalled
|
services/core/java/com/android/server/wm/ActivityTaskManagerService.java
|
1120bc7e511710b1b774adf29ba47106292365e7
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public List<Review> getByMovieId(int movieId) {
return find.where().eq("movieId", movieId).findList();
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getByMovieId
File: app/business/impl/ReviewServiceImpl.java
Repository: danynab/movify-j
The code follows secure coding practices.
|
[
"CWE-89"
] |
CVE-2015-10068
|
MEDIUM
| 5.2
|
danynab/movify-j
|
getByMovieId
|
app/business/impl/ReviewServiceImpl.java
|
c3085e01936a4d7eff1eda3093f25d56cc4d2ec5
| 0
|
Analyze the following code function for security vulnerabilities
|
RoleManager getRoleManager() {
return mContext.getSystemService(RoleManager.class);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getRoleManager
File: services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-862"
] |
CVE-2023-40089
|
HIGH
| 7.8
|
android
|
getRoleManager
|
services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
|
e2e05f488da6abc765a62e7faf10cb74e729732e
| 0
|
Analyze the following code function for security vulnerabilities
|
public DataProvider<T, ?> getDataProvider() {
return dataProvider;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getDataProvider
File: server/src/main/java/com/vaadin/data/provider/DataCommunicator.java
Repository: vaadin/framework
The code follows secure coding practices.
|
[
"CWE-20"
] |
CVE-2021-33609
|
MEDIUM
| 4
|
vaadin/framework
|
getDataProvider
|
server/src/main/java/com/vaadin/data/provider/DataCommunicator.java
|
9a93593d9f3802d2881fc8ad22dbc210d0d1d295
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public GroupDetails loadGroupByGroupname(String groupname) throws UsernameNotFoundException, DataAccessException {
throw new UsernameNotFoundException(groupname);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: loadGroupByGroupname
File: core/src/main/java/hudson/security/HudsonPrivateSecurityRealm.java
Repository: jenkinsci/jenkins
The code follows secure coding practices.
|
[
"CWE-200"
] |
CVE-2014-2064
|
MEDIUM
| 5
|
jenkinsci/jenkins
|
loadGroupByGroupname
|
core/src/main/java/hudson/security/HudsonPrivateSecurityRealm.java
|
fbf96734470caba9364f04e0b77b0bae7293a1ec
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public ACL getACL() {
return authorizationStrategy.getRootACL();
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getACL
File: core/src/main/java/jenkins/model/Jenkins.java
Repository: jenkinsci/jenkins
The code follows secure coding practices.
|
[
"CWE-79"
] |
CVE-2014-2065
|
MEDIUM
| 4.3
|
jenkinsci/jenkins
|
getACL
|
core/src/main/java/jenkins/model/Jenkins.java
|
a0b00508eeb74d7033dc4100eb382df4e8fa72e7
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public List<ResolveInfo> queryIntentReceivers(Intent intent, String resolvedType, int flags,
int userId) {
if (!sUserManager.exists(userId)) return Collections.emptyList();
ComponentName comp = intent.getComponent();
if (comp == null) {
if (intent.getSelector() != null) {
intent = intent.getSelector();
comp = intent.getComponent();
}
}
if (comp != null) {
List<ResolveInfo> list = new ArrayList<ResolveInfo>(1);
ActivityInfo ai = getReceiverInfo(comp, flags, userId);
if (ai != null) {
ResolveInfo ri = new ResolveInfo();
ri.activityInfo = ai;
list.add(ri);
}
return list;
}
// reader
synchronized (mPackages) {
String pkgName = intent.getPackage();
if (pkgName == null) {
return mReceivers.queryIntent(intent, resolvedType, flags, userId);
}
final PackageParser.Package pkg = mPackages.get(pkgName);
if (pkg != null) {
return mReceivers.queryIntentForPackage(intent, resolvedType, flags, pkg.receivers,
userId);
}
return null;
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: queryIntentReceivers
File: services/core/java/com/android/server/pm/PackageManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-119"
] |
CVE-2016-2497
|
HIGH
| 7.5
|
android
|
queryIntentReceivers
|
services/core/java/com/android/server/pm/PackageManagerService.java
|
a75537b496e9df71c74c1d045ba5569631a16298
| 0
|
Analyze the following code function for security vulnerabilities
|
private static boolean isNumber(String s) {
try {
Integer.parseInt(s);
} catch (NumberFormatException nfe) {
return false;
}
return true;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: isNumber
File: cmds/pm/src/com/android/commands/pm/Pm.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-264"
] |
CVE-2016-3833
|
HIGH
| 9.3
|
android
|
isNumber
|
cmds/pm/src/com/android/commands/pm/Pm.java
|
4e4743a354e26467318b437892a9980eb9b8328a
| 0
|
Analyze the following code function for security vulnerabilities
|
private static File getCalledPreBootReceiversFile() {
File dataDir = Environment.getDataDirectory();
File systemDir = new File(dataDir, "system");
File fname = new File(systemDir, CALLED_PRE_BOOTS_FILENAME);
return fname;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getCalledPreBootReceiversFile
File: services/core/java/com/android/server/am/ActivityManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-284"
] |
CVE-2015-3833
|
MEDIUM
| 4.3
|
android
|
getCalledPreBootReceiversFile
|
services/core/java/com/android/server/am/ActivityManagerService.java
|
aaa0fee0d7a8da347a0c47cef5249c70efee209e
| 0
|
Analyze the following code function for security vulnerabilities
|
protected Vector<Object> getXObjects(List<BaseObject> objects)
{
if (objects == null) {
return new Vector<Object>(0);
}
Vector<Object> result = new Vector<Object>(objects.size());
for (BaseObject bobj : objects) {
if (bobj != null) {
result.add(newObjectApi(bobj, getXWikiContext()));
}
}
return result;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getXObjects
File: xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/api/Document.java
Repository: xwiki/xwiki-platform
The code follows secure coding practices.
|
[
"CWE-863"
] |
CVE-2022-23615
|
MEDIUM
| 5.5
|
xwiki/xwiki-platform
|
getXObjects
|
xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/api/Document.java
|
7ab0fe7b96809c7a3881454147598d46a1c9bbbe
| 0
|
Analyze the following code function for security vulnerabilities
|
private boolean addSharedAccountAsUser(Account account, int userId) {
userId = handleIncomingUser(userId);
UserAccounts accounts = getUserAccounts(userId);
accounts.accountsDb.deleteSharedAccount(account);
long accountId = accounts.accountsDb.insertSharedAccount(account);
if (accountId < 0) {
Log.w(TAG, "insertAccountIntoDatabase: " + account.toSafeString()
+ ", skipping the DB insert failed");
return false;
}
logRecord(AccountsDb.DEBUG_ACTION_ACCOUNT_ADD, AccountsDb.TABLE_SHARED_ACCOUNTS, accountId,
accounts);
return true;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: addSharedAccountAsUser
File: services/core/java/com/android/server/accounts/AccountManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other",
"CWE-502"
] |
CVE-2023-45777
|
HIGH
| 7.8
|
android
|
addSharedAccountAsUser
|
services/core/java/com/android/server/accounts/AccountManagerService.java
|
f810d81839af38ee121c446105ca67cb12992fc6
| 0
|
Analyze the following code function for security vulnerabilities
|
public UpdateCenter getUpdateCenter() {
return updateCenter;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getUpdateCenter
File: core/src/main/java/jenkins/model/Jenkins.java
Repository: jenkinsci/jenkins
The code follows secure coding practices.
|
[
"CWE-79"
] |
CVE-2014-2065
|
MEDIUM
| 4.3
|
jenkinsci/jenkins
|
getUpdateCenter
|
core/src/main/java/jenkins/model/Jenkins.java
|
a0b00508eeb74d7033dc4100eb382df4e8fa72e7
| 0
|
Analyze the following code function for security vulnerabilities
|
String getStartDateTime() {
if (startDateTime == null) {
startDateTime = DateTimeFormatter.ofPattern("EEE, d MMM yyyy HH:mm:ss z", Locale.ENGLISH)
.format(ZonedDateTime.now(ZoneId.of("UTC")));
}
return startDateTime;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getStartDateTime
File: h2/src/main/org/h2/server/web/WebServer.java
Repository: h2database
The code follows secure coding practices.
|
[
"CWE-312"
] |
CVE-2022-45868
|
HIGH
| 7.8
|
h2database
|
getStartDateTime
|
h2/src/main/org/h2/server/web/WebServer.java
|
23ee3d0b973923c135fa01356c8eaed40b895393
| 0
|
Analyze the following code function for security vulnerabilities
|
@Test
public void parseQueryMTypeWDS() throws Exception {
HttpQuery query = NettyMocks.getQuery(tsdb,
"/api/query?start=1h-ago&m=sum:1h-avg:sys.cpu.0");
TSQuery tsq = (TSQuery) parseQuery.invoke(rpc, tsdb, query, expressions);
TSSubQuery sub = tsq.getQueries().get(0);
assertEquals("1h-avg", sub.getDownsample());
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: parseQueryMTypeWDS
File: test/tsd/TestQueryRpc.java
Repository: OpenTSDB/opentsdb
The code follows secure coding practices.
|
[
"CWE-79"
] |
CVE-2023-25827
|
MEDIUM
| 6.1
|
OpenTSDB/opentsdb
|
parseQueryMTypeWDS
|
test/tsd/TestQueryRpc.java
|
ff02c1e95e60528275f69b31bcbf7b2ac625cea8
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public void grantRuntimePermission(String packageName, String name, final int userId) {
if (!sUserManager.exists(userId)) {
Log.e(TAG, "No such user:" + userId);
return;
}
mContext.enforceCallingOrSelfPermission(
android.Manifest.permission.GRANT_RUNTIME_PERMISSIONS,
"grantRuntimePermission");
enforceCrossUserPermission(Binder.getCallingUid(), userId, true, false,
"grantRuntimePermission");
final int uid;
final SettingBase sb;
synchronized (mPackages) {
final PackageParser.Package pkg = mPackages.get(packageName);
if (pkg == null) {
throw new IllegalArgumentException("Unknown package: " + packageName);
}
final BasePermission bp = mSettings.mPermissions.get(name);
if (bp == null) {
throw new IllegalArgumentException("Unknown permission: " + name);
}
enforceDeclaredAsUsedAndRuntimeOrDevelopmentPermission(pkg, bp);
uid = UserHandle.getUid(userId, pkg.applicationInfo.uid);
sb = (SettingBase) pkg.mExtras;
if (sb == null) {
throw new IllegalArgumentException("Unknown package: " + packageName);
}
final PermissionsState permissionsState = sb.getPermissionsState();
final int flags = permissionsState.getPermissionFlags(name, userId);
if ((flags & PackageManager.FLAG_PERMISSION_SYSTEM_FIXED) != 0) {
throw new SecurityException("Cannot grant system fixed permission: "
+ name + " for package: " + packageName);
}
if (bp.isDevelopment()) {
// Development permissions must be handled specially, since they are not
// normal runtime permissions. For now they apply to all users.
if (permissionsState.grantInstallPermission(bp) !=
PermissionsState.PERMISSION_OPERATION_FAILURE) {
scheduleWriteSettingsLocked();
}
return;
}
final int result = permissionsState.grantRuntimePermission(bp, userId);
switch (result) {
case PermissionsState.PERMISSION_OPERATION_FAILURE: {
return;
}
case PermissionsState.PERMISSION_OPERATION_SUCCESS_GIDS_CHANGED: {
final int appId = UserHandle.getAppId(pkg.applicationInfo.uid);
mHandler.post(new Runnable() {
@Override
public void run() {
killUid(appId, userId, KILL_APP_REASON_GIDS_CHANGED);
}
});
}
break;
}
mOnPermissionChangeListeners.onPermissionsChanged(uid);
// Not critical if that is lost - app has to request again.
mSettings.writeRuntimePermissionsForUserLPr(userId, false);
}
// Only need to do this if user is initialized. Otherwise it's a new user
// and there are no processes running as the user yet and there's no need
// to make an expensive call to remount processes for the changed permissions.
if (READ_EXTERNAL_STORAGE.equals(name)
|| WRITE_EXTERNAL_STORAGE.equals(name)) {
final long token = Binder.clearCallingIdentity();
try {
if (sUserManager.isInitialized(userId)) {
MountServiceInternal mountServiceInternal = LocalServices.getService(
MountServiceInternal.class);
mountServiceInternal.onExternalStoragePolicyChanged(uid, packageName);
}
} finally {
Binder.restoreCallingIdentity(token);
}
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: grantRuntimePermission
File: services/core/java/com/android/server/pm/PackageManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-119"
] |
CVE-2016-2497
|
HIGH
| 7.5
|
android
|
grantRuntimePermission
|
services/core/java/com/android/server/pm/PackageManagerService.java
|
a75537b496e9df71c74c1d045ba5569631a16298
| 0
|
Analyze the following code function for security vulnerabilities
|
public void setCustomClass(String customClass)
{
getDoc().setCustomClass(customClass);
updateAuthor();
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: setCustomClass
File: xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/api/Document.java
Repository: xwiki/xwiki-platform
The code follows secure coding practices.
|
[
"CWE-863"
] |
CVE-2022-23615
|
MEDIUM
| 5.5
|
xwiki/xwiki-platform
|
setCustomClass
|
xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/api/Document.java
|
7ab0fe7b96809c7a3881454147598d46a1c9bbbe
| 0
|
Analyze the following code function for security vulnerabilities
|
private String chooseFileName(boolean ownXmlFormat, FileFilter filefilter, JFileChooser fileChooser) {
String fileName = null;
setAvailableFileFilters(ownXmlFormat, fileChooser);
fileChooser.setFileFilter(filefilter);
int returnVal = fileChooser.showSaveDialog(CurrentGui.getInstance().getGui().getMainFrame());
if (returnVal == JFileChooser.APPROVE_OPTION) {
File selectedFileWithExt = getFileWithExtension(fileChooser);
if (selectedFileWithExt.exists()) {
int overwriteQuestionResult = JOptionPane.showConfirmDialog(CurrentGui.getInstance().getGui().getMainFrame(), "File already exists! Overwrite?", "Overwrite File", JOptionPane.YES_NO_OPTION);
if (overwriteQuestionResult == JOptionPane.NO_OPTION) {
return chooseFileName(ownXmlFormat, filefilter, fileChooser);
}
}
fileName = selectedFileWithExt.getAbsolutePath();
}
return fileName;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: chooseFileName
File: umlet-swing/src/main/java/com/baselet/diagram/io/DiagramFileHandler.java
Repository: umlet
The code follows secure coding practices.
|
[
"CWE-611"
] |
CVE-2018-1000548
|
MEDIUM
| 6.8
|
umlet
|
chooseFileName
|
umlet-swing/src/main/java/com/baselet/diagram/io/DiagramFileHandler.java
|
e1c4cc6ae692cc8d1c367460dbf79343e996f9bd
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
protected void removeServiceInterface() {
Log.v(this, "Removing Connection Service Adapter.");
removeConnectionServiceAdapter(mAdapter);
// We have lost our service connection. Notify the world that this service is done.
// We must notify the adapter before CallsManager. The adapter will force any pending
// outgoing calls to try the next service. This needs to happen before CallsManager
// tries to clean up any calls still associated with this service.
handleConnectionServiceDeath();
mCallsManager.handleConnectionServiceDeath(this);
mServiceInterface = null;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: removeServiceInterface
File: src/com/android/server/telecom/ConnectionServiceWrapper.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2023-21283
|
MEDIUM
| 5.5
|
android
|
removeServiceInterface
|
src/com/android/server/telecom/ConnectionServiceWrapper.java
|
9b41a963f352fdb3da1da8c633d45280badfcb24
| 0
|
Analyze the following code function for security vulnerabilities
|
private void updateDialerAndSmsManagedShortcutsOverrideCache() {
ArrayMap<String, String> shortcutOverrides = new ArrayMap<>();
int managedUserId = getManagedUserId();
List<String> dialerRoleHolders = mRoleManager.getRoleHoldersAsUser(RoleManager.ROLE_DIALER,
UserHandle.of(managedUserId));
List<String> smsRoleHolders = mRoleManager.getRoleHoldersAsUser(RoleManager.ROLE_SMS,
UserHandle.of(managedUserId));
String dialerPackageToOverride = getOemDefaultDialerPackage();
String smsPackageToOverride = getOemDefaultSmsPackage();
// To get the default app, we can get all the role holders and get the first element.
if (dialerPackageToOverride != null) {
shortcutOverrides.put(dialerPackageToOverride,
dialerRoleHolders.isEmpty() ? dialerPackageToOverride
: dialerRoleHolders.get(0));
}
if (smsPackageToOverride != null) {
shortcutOverrides.put(smsPackageToOverride,
smsRoleHolders.isEmpty() ? smsPackageToOverride : smsRoleHolders.get(0));
}
mPolicyCache.setLauncherShortcutOverrides(shortcutOverrides);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: updateDialerAndSmsManagedShortcutsOverrideCache
File: services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-862"
] |
CVE-2023-40089
|
HIGH
| 7.8
|
android
|
updateDialerAndSmsManagedShortcutsOverrideCache
|
services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
|
e2e05f488da6abc765a62e7faf10cb74e729732e
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public String method() {
return method;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: method
File: jooby/src/main/java/org/jooby/internal/RouteImpl.java
Repository: jooby-project/jooby
The code follows secure coding practices.
|
[
"CWE-79"
] |
CVE-2019-15477
|
MEDIUM
| 4.3
|
jooby-project/jooby
|
method
|
jooby/src/main/java/org/jooby/internal/RouteImpl.java
|
34856a738829d8fedca4ed27bd6ff413af87186f
| 0
|
Analyze the following code function for security vulnerabilities
|
public boolean isResourceProviderInDevelopmentMode(String providerName) {
return resourceProvidersInDevelopmentMode.contains(providerName);
}
|
Vulnerability Classification:
- CWE: CWE-22
- CVE: CVE-2020-24621
- Severity: MEDIUM
- CVSS Score: 6.5
Description: UIFR-215: Do not allow loading arbitrary files
Function: isResourceProviderInDevelopmentMode
File: api/src/main/java/org/openmrs/ui/framework/resource/ResourceFactory.java
Repository: openmrs/openmrs-module-uiframework
Fixed Code:
public boolean isResourceProviderInDevelopmentMode(String providerName) {
return resourceProvidersInDevelopmentMode.contains(providerName);
}
|
[
"CWE-22"
] |
CVE-2020-24621
|
MEDIUM
| 6.5
|
openmrs/openmrs-module-uiframework
|
isResourceProviderInDevelopmentMode
|
api/src/main/java/org/openmrs/ui/framework/resource/ResourceFactory.java
|
0422fa52c7eba3d96cce2936cb92897dca4b680a
| 1
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.