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
|
public boolean getInvertFilter() {
return invertFilter;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getInvertFilter
File: config/config-api/src/main/java/com/thoughtworks/go/config/materials/ScmMaterialConfig.java
Repository: gocd
The code follows secure coding practices.
|
[
"CWE-77"
] |
CVE-2021-43286
|
MEDIUM
| 6.5
|
gocd
|
getInvertFilter
|
config/config-api/src/main/java/com/thoughtworks/go/config/materials/ScmMaterialConfig.java
|
6fa9fb7a7c91e760f1adc2593acdd50f2d78676b
| 0
|
Analyze the following code function for security vulnerabilities
|
@Beta
@Deprecated
public
static String readFirstLine(File file, Charset charset) throws IOException {
return asCharSource(file, charset).readFirstLine();
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: readFirstLine
File: android/guava/src/com/google/common/io/Files.java
Repository: google/guava
The code follows secure coding practices.
|
[
"CWE-732"
] |
CVE-2020-8908
|
LOW
| 2.1
|
google/guava
|
readFirstLine
|
android/guava/src/com/google/common/io/Files.java
|
fec0dbc4634006a6162cfd4d0d09c962073ddf40
| 0
|
Analyze the following code function for security vulnerabilities
|
public void waitForVisualStateCallback(final AwContents awContents) throws Exception {
final CallbackHelper ch = new CallbackHelper();
final int chCount = ch.getCallCount();
getInstrumentation().runOnMainSync(new Runnable() {
@Override
public void run() {
final long requestId = 666;
awContents.insertVisualStateCallback(requestId,
new AwContents.VisualStateCallback() {
@Override
public void onComplete(long id) {
assertEquals(requestId, id);
ch.notifyCalled();
}
});
}
});
ch.waitForCallback(chCount);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: waitForVisualStateCallback
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
|
waitForVisualStateCallback
|
android_webview/javatests/src/org/chromium/android_webview/test/AwTestBase.java
|
b8dcfeb065bbfd777cdc5f5433da9a87f25e6ec6
| 0
|
Analyze the following code function for security vulnerabilities
|
private static String getQualifiedName(final String namespaceURI, final String localName) {
final String qualifiedName;
if (namespaceURI != null && !namespaceURI.isEmpty() && !"null".equals(namespaceURI)) {
qualifiedName = '{' + namespaceURI + '}' + localName;
}
else {
qualifiedName = localName;
}
return qualifiedName;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getQualifiedName
File: src/main/java/com/gargoylesoftware/htmlunit/javascript/host/xml/XSLTProcessor.java
Repository: HtmlUnit/htmlunit
The code follows secure coding practices.
|
[
"CWE-94"
] |
CVE-2023-26119
|
CRITICAL
| 9.8
|
HtmlUnit/htmlunit
|
getQualifiedName
|
src/main/java/com/gargoylesoftware/htmlunit/javascript/host/xml/XSLTProcessor.java
|
641325bbc84702dc9800ec7037aec061ce21956b
| 0
|
Analyze the following code function for security vulnerabilities
|
protected boolean scanMarkupContent(XMLStringBuffer buffer,
char cend) throws IOException {
int c = -1;
OUTER: while (true) {
c = fCurrentEntity.read();
if (c == cend) {
int count = 1;
while (true) {
c = fCurrentEntity.read();
if (c == cend) {
count++;
continue;
}
break;
}
if (c == -1) {
if (fReportErrors) {
fErrorReporter.reportError("HTML1007", null);
}
break OUTER;
}
if (count < 2) {
buffer.append(cend);
//if (c != -1) {
fCurrentEntity.rewind();
//}
continue;
}
if (c != '>') {
for (int i = 0; i < count; i++) {
buffer.append(cend);
}
fCurrentEntity.rewind();
continue;
}
for (int i = 0; i < count - 2; i++) {
buffer.append(cend);
}
break;
}
else if (c == '\n' || c == '\r') {
fCurrentEntity.rewind();
int newlines = skipNewlines();
for (int i = 0; i < newlines; i++) {
buffer.append('\n');
}
continue;
}
else if (c == -1) {
if (fReportErrors) {
fErrorReporter.reportError("HTML1007", null);
}
break;
}
appendChar(buffer, c);
}
return c == -1;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: scanMarkupContent
File: src/org/cyberneko/html/HTMLScanner.java
Repository: sparklemotion/nekohtml
The code follows secure coding practices.
|
[
"CWE-400"
] |
CVE-2022-24839
|
MEDIUM
| 5
|
sparklemotion/nekohtml
|
scanMarkupContent
|
src/org/cyberneko/html/HTMLScanner.java
|
a800fce3b079def130ed42a408ff1d09f89e773d
| 0
|
Analyze the following code function for security vulnerabilities
|
private void askForUserApprovalForCaCertificate() {
if (mCurrentTofuConfig == null || TextUtils.isEmpty(mCurrentTofuConfig.SSID)) return;
if (useTrustOnFirstUse()) {
if (null == mPendingRootCaCert || null == mPendingServerCert) {
Log.e(TAG, "Cannot launch a dialog for TOFU without "
+ "a valid pending CA certificate.");
return;
}
}
dismissDialogAndNotification();
String title = useTrustOnFirstUse()
? mContext.getString(R.string.wifi_ca_cert_dialog_title)
: mContext.getString(R.string.wifi_ca_cert_dialog_preT_title);
String positiveButtonText = useTrustOnFirstUse()
? mContext.getString(R.string.wifi_ca_cert_dialog_continue_text)
: mContext.getString(R.string.wifi_ca_cert_dialog_preT_continue_text);
String negativeButtonText = useTrustOnFirstUse()
? mContext.getString(R.string.wifi_ca_cert_dialog_abort_text)
: mContext.getString(R.string.wifi_ca_cert_dialog_preT_abort_text);
String message;
String messageUrl = null;
int messageUrlStart = 0;
int messageUrlEnd = 0;
if (useTrustOnFirstUse()) {
StringBuilder contentBuilder = new StringBuilder()
.append(mContext.getString(R.string.wifi_ca_cert_dialog_message_hint))
.append(mContext.getString(
R.string.wifi_ca_cert_dialog_message_server_name_text,
mPendingServerCertSubjectInfo.commonName))
.append(mContext.getString(
R.string.wifi_ca_cert_dialog_message_issuer_name_text,
mPendingServerCertIssuerInfo.commonName));
if (!TextUtils.isEmpty(mPendingServerCertSubjectInfo.organization)) {
contentBuilder.append(mContext.getString(
R.string.wifi_ca_cert_dialog_message_organization_text,
mPendingServerCertSubjectInfo.organization));
}
final Date expiration = mPendingServerCert.getNotAfter();
if (expiration != null) {
contentBuilder.append(mContext.getString(
R.string.wifi_ca_cert_dialog_message_expiration_text,
DateFormat.getMediumDateFormat(mContext).format(expiration)));
}
final String fingerprint = getDigest(mPendingServerCert, "SHA256");
if (!TextUtils.isEmpty(fingerprint)) {
contentBuilder.append(mContext.getString(
R.string.wifi_ca_cert_dialog_message_signature_name_text, fingerprint));
}
message = contentBuilder.toString();
} else {
String hint = mContext.getString(
R.string.wifi_ca_cert_dialog_preT_message_hint, mCurrentTofuConfig.SSID);
String linkText = mContext.getString(
R.string.wifi_ca_cert_dialog_preT_message_link);
message = hint + " " + linkText;
messageUrl = mCaCertHelpLink;
messageUrlStart = hint.length() + 1;
messageUrlEnd = message.length();
}
mTofuAlertDialog = mWifiDialogManager.createSimpleDialogWithUrl(
title,
message,
messageUrl,
messageUrlStart,
messageUrlEnd,
positiveButtonText,
negativeButtonText,
null /* neutralButtonText */,
new WifiDialogManager.SimpleDialogCallback() {
@Override
public void onPositiveButtonClicked() {
if (mCurrentTofuConfig == null) {
return;
}
Log.d(TAG, "User accepted the server certificate");
handleAccept(mCurrentTofuConfig.SSID);
}
@Override
public void onNegativeButtonClicked() {
if (mCurrentTofuConfig == null) {
return;
}
Log.d(TAG, "User rejected the server certificate");
handleReject(mCurrentTofuConfig.SSID);
}
@Override
public void onNeutralButtonClicked() {
// Not used.
if (mCurrentTofuConfig == null) {
return;
}
Log.d(TAG, "User input neutral");
handleReject(mCurrentTofuConfig.SSID);
}
@Override
public void onCancelled() {
if (mCurrentTofuConfig == null) {
return;
}
Log.d(TAG, "User input canceled");
handleReject(mCurrentTofuConfig.SSID);
}
},
new WifiThreadRunner(mHandler));
mTofuAlertDialog.launchDialog();
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: askForUserApprovalForCaCertificate
File: service/java/com/android/server/wifi/InsecureEapNetworkHandler.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2023-21242
|
CRITICAL
| 9.8
|
android
|
askForUserApprovalForCaCertificate
|
service/java/com/android/server/wifi/InsecureEapNetworkHandler.java
|
72e903f258b5040b8f492cf18edd124b5a1ac770
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
boolean check(SecurityConfig c1, SecurityConfig c2) {
return c1 == c2 || !(c1 == null || c2 == null)
&& nullSafeEqual(c1.isEnabled(), c2.isEnabled())
&& nullSafeEqual(c1.getClientBlockUnmappedActions(), c2.getClientBlockUnmappedActions())
&& isCompatible(c1.getMemberCredentialsConfig(), c2.getMemberCredentialsConfig())
&& isCompatible(c1.getSecurityInterceptorConfigs(), c2.getSecurityInterceptorConfigs())
&& isCompatible(c1.getClientPolicyConfig(), c2.getClientPolicyConfig())
&& isCompatible(c1.getClientPermissionConfigs(), c2.getClientPermissionConfigs())
&& isCompatibleLoginModule(c1.getMemberLoginModuleConfigs(), c2.getMemberLoginModuleConfigs())
&& isCompatibleLoginModule(c1.getClientLoginModuleConfigs(), c2.getClientLoginModuleConfigs());
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: check
File: hazelcast/src/test/java/com/hazelcast/config/ConfigCompatibilityChecker.java
Repository: hazelcast
The code follows secure coding practices.
|
[
"CWE-502"
] |
CVE-2016-10750
|
MEDIUM
| 6.8
|
hazelcast
|
check
|
hazelcast/src/test/java/com/hazelcast/config/ConfigCompatibilityChecker.java
|
c1c31359a1df953e79a9ca9b6c54b3cdbfef11e9
| 0
|
Analyze the following code function for security vulnerabilities
|
public static List<String> getAuthorsStrings(boolean withTag) {
final List<String> strings = new ArrayList<>();
add(strings, "<b>PlantUML version " + Version.versionString() + "</b> (" + Version.compileTimeString() + ")",
withTag);
add(strings, "(" + License.getCurrent() + " source distribution)", withTag);
add(strings, " ", withTag);
add(strings, "<u>Original idea</u>: Arnaud Roques", withTag);
add(strings, "<u>Word Macro</u>: Alain Bertucat & Matthieu Sabatier", withTag);
add(strings, "<u>Word Add-in</u>: Adriaan van den Brand", withTag);
add(strings, "<u>J2V8 & viz.js integration</u>: Andreas Studer", withTag);
add(strings, "<u>Official Eclipse Plugin</u>: Hallvard Tr\u00E6tteberg", withTag);
add(strings, "<u>Original Eclipse Plugin</u>: Claude Durif & Anne Pecoil", withTag);
add(strings, "<u>Servlet & XWiki</u>: Maxime Sinclair", withTag);
add(strings, "<u>Docker</u>: David Ducatel", withTag);
add(strings, "<u>AWS lib</u>: Chris Passarello", withTag);
add(strings, "<u>Stdlib Icons</u>: tupadr3", withTag);
add(strings, "<u>Site design</u>: Raphael Cotisson", withTag);
add(strings, "<u>Logo</u>: Benjamin Croizet", withTag);
add(strings, "<u>Web Assembly</u>: Sakir Temel", withTag);
add(strings, " ", withTag);
add(strings, "https://plantuml.com", withTag);
add(strings, " ", withTag);
return strings;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getAuthorsStrings
File: src/net/sourceforge/plantuml/version/PSystemVersion.java
Repository: plantuml
The code follows secure coding practices.
|
[
"CWE-284"
] |
CVE-2023-3431
|
MEDIUM
| 5.3
|
plantuml
|
getAuthorsStrings
|
src/net/sourceforge/plantuml/version/PSystemVersion.java
|
fbe7fa3b25b4c887d83927cffb1009ec6cb8ab1e
| 0
|
Analyze the following code function for security vulnerabilities
|
private AttributedString highlight(CmdDesc cmdDesc) {
StringBuilder sb = new StringBuilder();
for (AttributedString as : cmdDesc.getMainDesc()) {
sb.append(as.toString());
sb.append("\n");
}
List<Integer> tabs = Arrays.asList(0, 2, 33);
for (Map.Entry<String, List<AttributedString>> entry :
cmdDesc.getOptsDesc().entrySet()) {
AttributedStringBuilder asb = new AttributedStringBuilder();
asb.tabs(tabs);
asb.append("\t");
asb.append(entry.getKey());
asb.append("\t");
boolean first = true;
for (AttributedString as : entry.getValue()) {
if (!first) {
asb.append("\t");
asb.append("\t");
}
asb.append(as);
asb.append("\n");
first = false;
}
sb.append(asb);
}
return Options.HelpException.highlight(sb.toString(), Styles.helpStyle());
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: highlight
File: console/src/main/java/org/jline/console/impl/DefaultPrinter.java
Repository: jline/jline3
The code follows secure coding practices.
|
[
"CWE-787"
] |
CVE-2023-50572
|
MEDIUM
| 5.5
|
jline/jline3
|
highlight
|
console/src/main/java/org/jline/console/impl/DefaultPrinter.java
|
f3c60a3e6255e8e0c20d5043a4fe248446f292bb
| 0
|
Analyze the following code function for security vulnerabilities
|
private VelocityContextFactory getVelocityContextFactory()
{
if (this.velocityContextFactory == null) {
this.velocityContextFactory = Utils.getComponent(VelocityContextFactory.class);
}
return this.velocityContextFactory;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getVelocityContextFactory
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
|
getVelocityContextFactory
|
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
|
void onCanAddCallChanged(boolean canAddCall);
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: onCanAddCallChanged
File: src/com/android/server/telecom/CallsManager.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-264"
] |
CVE-2016-2423
|
MEDIUM
| 6.6
|
android
|
onCanAddCallChanged
|
src/com/android/server/telecom/CallsManager.java
|
a06c9a4aef69ae27b951523cf72bf72412bf48fa
| 0
|
Analyze the following code function for security vulnerabilities
|
public boolean dumpHeap(String process, int userId, boolean managed, String path,
ParcelFileDescriptor fd) throws RemoteException;
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: dumpHeap
File: core/java/android/app/IActivityManager.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-264"
] |
CVE-2016-3832
|
HIGH
| 8.3
|
android
|
dumpHeap
|
core/java/android/app/IActivityManager.java
|
e7cf91a198de995c7440b3b64352effd2e309906
| 0
|
Analyze the following code function for security vulnerabilities
|
private boolean canGetPhoneAccount(String callingPackage, PhoneAccountHandle accountHandle) {
// Allow default dialer, system dialer and sim call manager to be able to do this without
// extra permission
try {
if (isPrivilegedDialerCalling(callingPackage) || isCallerSimCallManager(
accountHandle)) {
return true;
}
} catch (SecurityException e) {
// ignore
}
try {
mContext.enforceCallingOrSelfPermission(READ_PRIVILEGED_PHONE_STATE, null);
return true;
} catch (SecurityException e) {
// Accessing phone state is gated by a special permission.
mContext.enforceCallingOrSelfPermission(READ_PHONE_NUMBERS, null);
return true;
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: canGetPhoneAccount
File: src/com/android/server/telecom/TelecomServiceImpl.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2023-21394
|
MEDIUM
| 5.5
|
android
|
canGetPhoneAccount
|
src/com/android/server/telecom/TelecomServiceImpl.java
|
68dca62035c49e14ad26a54f614199cb29a3393f
| 0
|
Analyze the following code function for security vulnerabilities
|
public static Service getService(Map environment)
{
Service service = null;
InitialContext context = null;
EngineConfiguration configProvider =
(EngineConfiguration)environment.get(EngineConfiguration.PROPERTY_NAME);
if (configProvider == null)
configProvider = (EngineConfiguration)threadDefaultConfig.get();
if (configProvider == null)
configProvider = getDefaultEngineConfig();
// First check to see if JNDI works
// !!! Might we need to set up context parameters here?
try {
context = new InitialContext();
} catch (NamingException e) {
}
if (context != null) {
String name = (String)environment.get("jndiName");
if (name == null) {
name = "axisServiceName";
}
// We've got JNDI, so try to find an AxisClient at the
// specified name.
try {
service = (Service)context.lookup(name);
} catch (NamingException e) {
service = new Service(configProvider);
try {
context.bind(name, service);
} catch (NamingException e1) {
// !!! Couldn't do it, what should we do here?
}
}
} else {
service = new Service(configProvider);
}
return service;
}
|
Vulnerability Classification:
- CWE: CWE-20
- CVE: CVE-2023-40743
- Severity: CRITICAL
- CVSS Score: 9.8
Description: Filter out unsupported protocols in the client class ServiceFactory
Function: getService
File: axis-rt-core/src/main/java/org/apache/axis/client/ServiceFactory.java
Repository: apache/axis-axis1-java
Fixed Code:
public static Service getService(Map environment)
{
Service service = null;
InitialContext context = null;
EngineConfiguration configProvider =
(EngineConfiguration)environment.get(EngineConfiguration.PROPERTY_NAME);
if (configProvider == null)
configProvider = (EngineConfiguration)threadDefaultConfig.get();
if (configProvider == null)
configProvider = getDefaultEngineConfig();
// First check to see if JNDI works
// !!! Might we need to set up context parameters here?
try {
context = new InitialContext();
} catch (NamingException e) {
}
if (context != null) {
String name = (String)environment.get("jndiName");
if(name!=null && (name.toUpperCase().indexOf("LDAP")!=-1 || name.toUpperCase().indexOf("RMI")!=-1 || name.toUpperCase().indexOf("JMS")!=-1 || name.toUpperCase().indexOf("JMX")!=-1) || name.toUpperCase().indexOf("JRMP")!=-1 || name.toUpperCase().indexOf("JAVA")!=-1 || name.toUpperCase().indexOf("DNS")!=-1) {
return null;
}
if (name == null) {
name = "axisServiceName";
}
// We've got JNDI, so try to find an AxisClient at the
// specified name.
try {
service = (Service)context.lookup(name);
} catch (NamingException e) {
service = new Service(configProvider);
try {
context.bind(name, service);
} catch (NamingException e1) {
// !!! Couldn't do it, what should we do here?
return null;
}
}
} else {
service = new Service(configProvider);
}
return service;
}
|
[
"CWE-20"
] |
CVE-2023-40743
|
CRITICAL
| 9.8
|
apache/axis-axis1-java
|
getService
|
axis-rt-core/src/main/java/org/apache/axis/client/ServiceFactory.java
|
7e66753427466590d6def0125e448d2791723210
| 1
|
Analyze the following code function for security vulnerabilities
|
void setFocusedStackFrame() {
final TaskStack stack;
if (mFocusedApp != null) {
final Task task = mFocusedApp.mTask;
stack = task.mStack;
final DisplayContent displayContent = task.getDisplayContent();
if (displayContent != null) {
displayContent.setTouchExcludeRegion(stack);
}
} else {
stack = null;
}
mFocusedStackFrame.setVisibility(stack);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: setFocusedStackFrame
File: services/core/java/com/android/server/wm/WindowManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-264"
] |
CVE-2016-3875
|
HIGH
| 7.2
|
android
|
setFocusedStackFrame
|
services/core/java/com/android/server/wm/WindowManagerService.java
|
69729fa8b13cadbf3173fe1f389fe4f3b7bd0f9c
| 0
|
Analyze the following code function for security vulnerabilities
|
public static String getResourcePath() {
return Jenkins.RESOURCE_PATH;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getResourcePath
File: core/src/main/java/hudson/Functions.java
Repository: jenkinsci/jenkins
The code follows secure coding practices.
|
[
"CWE-310"
] |
CVE-2014-2061
|
MEDIUM
| 5
|
jenkinsci/jenkins
|
getResourcePath
|
core/src/main/java/hudson/Functions.java
|
bf539198564a1108b7b71a973bf7de963a6213ef
| 0
|
Analyze the following code function for security vulnerabilities
|
void agentErrorCleanup() {
mBackupDataName.delete();
mNewStateName.delete();
clearAgentState();
executeNextState(mQueue.isEmpty() ? BackupState.FINAL : BackupState.RUNNING_QUEUE);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: agentErrorCleanup
File: services/backup/java/com/android/server/backup/BackupManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-200"
] |
CVE-2016-3759
|
MEDIUM
| 5
|
android
|
agentErrorCleanup
|
services/backup/java/com/android/server/backup/BackupManagerService.java
|
9b8c6d2df35455ce9e67907edded1e4a2ecb9e28
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public String getHelpFile() {
return "/help/project-config/downstream.html";
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getHelpFile
File: core/src/main/java/hudson/tasks/BuildTrigger.java
Repository: jenkinsci/jenkins
The code follows secure coding practices.
|
[
"CWE-264"
] |
CVE-2013-7330
|
MEDIUM
| 4
|
jenkinsci/jenkins
|
getHelpFile
|
core/src/main/java/hudson/tasks/BuildTrigger.java
|
36342d71e29e0620f803a7470ce96c61761648d8
| 0
|
Analyze the following code function for security vulnerabilities
|
private void createSession( final AuthenticationInfo authInfo )
{
final Session session = this.context.get().getLocalScope().getSession();
if ( session != null )
{
session.setAttribute( authInfo );
}
if ( this.sessionTimeout != null )
{
setSessionTimeout();
}
}
|
Vulnerability Classification:
- CWE: CWE-384
- CVE: CVE-2024-23679
- Severity: CRITICAL
- CVSS Score: 9.8
Description: Invalidate old session after login #9253
(cherry picked from commit 0189975691e9e6407a9fee87006f730e84f734ff)
Function: createSession
File: modules/lib/lib-auth/src/main/java/com/enonic/xp/lib/auth/LoginHandler.java
Repository: enonic/xp
Fixed Code:
private void createSession( final AuthenticationInfo authInfo )
{
final LocalScope localScope = this.context.get().getLocalScope();
final Session session = localScope.getSession();
if ( session != null )
{
final var attributes = session.getAttributes();
session.invalidate();
final Session newSession = localScope.getSession();
if ( newSession != null )
{
attributes.forEach( newSession::setAttribute );
session.setAttribute( authInfo );
if ( this.sessionTimeout != null )
{
setSessionTimeout();
}
}
}
}
|
[
"CWE-384"
] |
CVE-2024-23679
|
CRITICAL
| 9.8
|
enonic/xp
|
createSession
|
modules/lib/lib-auth/src/main/java/com/enonic/xp/lib/auth/LoginHandler.java
|
2abac31cec8679074debc4f1fb69c25930e40842
| 1
|
Analyze the following code function for security vulnerabilities
|
public boolean isPathBased()
{
return "1".equals(getConfiguration().getProperty("xwiki.virtual.usepath", "1"));
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: isPathBased
File: xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/XWiki.java
Repository: xwiki/xwiki-platform
The code follows secure coding practices.
|
[
"CWE-863"
] |
CVE-2021-32620
|
MEDIUM
| 4
|
xwiki/xwiki-platform
|
isPathBased
|
xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/XWiki.java
|
f9a677408ffb06f309be46ef9d8df1915d9099a4
| 0
|
Analyze the following code function for security vulnerabilities
|
private boolean isGlobalAccessibilityGestureEnabled() {
return Settings.Global.getInt(mContext.getContentResolver(),
Settings.Global.ENABLE_ACCESSIBILITY_GLOBAL_GESTURE_ENABLED, 0) == 1;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: isGlobalAccessibilityGestureEnabled
File: policy/src/com/android/internal/policy/impl/PhoneWindowManager.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-264"
] |
CVE-2016-0812
|
MEDIUM
| 6.6
|
android
|
isGlobalAccessibilityGestureEnabled
|
policy/src/com/android/internal/policy/impl/PhoneWindowManager.java
|
84669ca8de55d38073a0dcb01074233b0a417541
| 0
|
Analyze the following code function for security vulnerabilities
|
boolean hasMethodReadObjectNoData() {
return (methodReadObjectNoData != null);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: hasMethodReadObjectNoData
File: luni/src/main/java/java/io/ObjectStreamClass.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-264"
] |
CVE-2014-7911
|
HIGH
| 7.2
|
android
|
hasMethodReadObjectNoData
|
luni/src/main/java/java/io/ObjectStreamClass.java
|
738c833d38d41f8f76eb7e77ab39add82b1ae1e2
| 0
|
Analyze the following code function for security vulnerabilities
|
private byte[] getPasswordHistoryHashFactor() {
if (mPasswordHistoryHashFactor == null) {
mPasswordHistoryHashFactor = mLockPatternUtils.getPasswordHistoryHashFactor(
mCurrentCredential != null ? mCurrentCredential
: LockscreenCredential.createNone(), mUserId);
}
return mPasswordHistoryHashFactor;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getPasswordHistoryHashFactor
File: src/com/android/settings/password/ChooseLockPassword.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2023-40117
|
HIGH
| 7.8
|
android
|
getPasswordHistoryHashFactor
|
src/com/android/settings/password/ChooseLockPassword.java
|
11815817de2f2d70fe842b108356a1bc75d44ffb
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public boolean shouldDelayChildPressedState() {
return true;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: shouldDelayChildPressedState
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
|
shouldDelayChildPressedState
|
libs/WindowManager/Shell/src/com/android/wm/shell/pip/phone/PipMenuView.java
|
7212a4bec2d2f1a74fa54a12a04255d6a183baa9
| 0
|
Analyze the following code function for security vulnerabilities
|
public List<Modification> latestModification() {
return gitLog("-1", "--date=iso", "--no-decorate", "--pretty=medium", "--no-color", remoteBranch());
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: latestModification
File: domain/src/main/java/com/thoughtworks/go/domain/materials/git/GitCommand.java
Repository: gocd
The code follows secure coding practices.
|
[
"CWE-77"
] |
CVE-2021-43286
|
MEDIUM
| 6.5
|
gocd
|
latestModification
|
domain/src/main/java/com/thoughtworks/go/domain/materials/git/GitCommand.java
|
6fa9fb7a7c91e760f1adc2593acdd50f2d78676b
| 0
|
Analyze the following code function for security vulnerabilities
|
public boolean isNavbarMenuLink2Enabled() {
return !StringUtils.isBlank(getNavbarMenuLink2URL());
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: isNavbarMenuLink2Enabled
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
|
isNavbarMenuLink2Enabled
|
src/main/java/com/erudika/scoold/utils/ScooldUtils.java
|
62a0e92e1486ddc17676a7ead2c07ff653d167ce
| 0
|
Analyze the following code function for security vulnerabilities
|
public String getCheckUrl(String userDefined, Object descriptor, String field) {
if(userDefined!=null || field==null) return userDefined;
if (descriptor instanceof Descriptor) {
Descriptor d = (Descriptor) descriptor;
return d.getCheckUrl(field);
}
return null;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getCheckUrl
File: core/src/main/java/hudson/Functions.java
Repository: jenkinsci/jenkins
The code follows secure coding practices.
|
[
"CWE-310"
] |
CVE-2014-2061
|
MEDIUM
| 5
|
jenkinsci/jenkins
|
getCheckUrl
|
core/src/main/java/hudson/Functions.java
|
bf539198564a1108b7b71a973bf7de963a6213ef
| 0
|
Analyze the following code function for security vulnerabilities
|
protected void securityRealmGenerator(XmlGenerator gen, String name, RealmConfig c) {
gen.open("realm", "name", name);
if (c.isAuthenticationConfigured()) {
gen.open("authentication");
jaasAuthenticationGenerator(gen, c.getJaasAuthenticationConfig());
tlsAuthenticationGenerator(gen, c.getTlsAuthenticationConfig());
ldapAuthenticationGenerator(gen, c.getLdapAuthenticationConfig());
kerberosAuthenticationGenerator(gen, c.getKerberosAuthenticationConfig());
simpleAuthenticationGenerator(gen, c.getSimpleAuthenticationConfig());
gen.close();
}
if (c.isIdentityConfigured()) {
gen.open("identity");
CredentialsFactoryConfig cf = c.getCredentialsFactoryConfig();
if (cf != null) {
gen.open("credentials-factory", "class-name", cf.getClassName()).appendProperties(cf.getProperties()).close();
}
UsernamePasswordIdentityConfig upi = c.getUsernamePasswordIdentityConfig();
if (upi != null) {
gen.node("username-password", null, "username", upi.getUsername(), "password", getOrMaskValue(upi.getPassword()));
}
TokenIdentityConfig ti = c.getTokenIdentityConfig();
if (ti != null) {
gen.node("token", getOrMaskValue(ti.getTokenEncoded()), "encoding", ti.getEncoding().toString());
}
kerberosIdentityGenerator(gen, c.getKerberosIdentityConfig());
gen.close();
}
gen.close();
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: securityRealmGenerator
File: hazelcast/src/main/java/com/hazelcast/config/ConfigXmlGenerator.java
Repository: hazelcast
The code follows secure coding practices.
|
[
"CWE-522"
] |
CVE-2023-33264
|
MEDIUM
| 4.3
|
hazelcast
|
securityRealmGenerator
|
hazelcast/src/main/java/com/hazelcast/config/ConfigXmlGenerator.java
|
80a502d53cc48bf895711ab55f95e3a51e344ac1
| 0
|
Analyze the following code function for security vulnerabilities
|
boolean isOutOfDate() {
return System.currentTimeMillis() - createDate > cacheEntryTimeout;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: isOutOfDate
File: vertx-web/src/main/java/io/vertx/ext/web/handler/impl/StaticHandlerImpl.java
Repository: vert-x3/vertx-web
The code follows secure coding practices.
|
[
"CWE-22"
] |
CVE-2018-12542
|
HIGH
| 7.5
|
vert-x3/vertx-web
|
isOutOfDate
|
vertx-web/src/main/java/io/vertx/ext/web/handler/impl/StaticHandlerImpl.java
|
57a65dce6f4c5aa5e3ce7288685e7f3447eb8f3b
| 0
|
Analyze the following code function for security vulnerabilities
|
public boolean isUsbDataSignalingEnabledForUser(@UserIdInt int userId) {
throwIfParentInstance("isUsbDataSignalingEnabledForUser");
if (mService != null) {
try {
return mService.isUsbDataSignalingEnabledForUser(userId);
} catch (RemoteException e) {
throw e.rethrowFromSystemServer();
}
}
return true;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: isUsbDataSignalingEnabledForUser
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
|
isUsbDataSignalingEnabledForUser
|
core/java/android/app/admin/DevicePolicyManager.java
|
e2e05f488da6abc765a62e7faf10cb74e729732e
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
boolean shouldAutoLaunchSingleChoice(TargetInfo target) {
final Intent intent = target.getResolvedIntent();
final ResolveInfo resolve = target.getResolveInfo();
// When GET_CONTENT is handled by the DocumentsUI system component,
// we're okay automatically launching it, since it offers it's own
// intent disambiguation UI.
if (intent != null && Intent.ACTION_GET_CONTENT.equals(intent.getAction())
&& resolve != null && resolve.priority > 0
&& resolve.activityInfo != null && DocumentsContract.PACKAGE_DOCUMENTS_UI
.equals(resolve.activityInfo.packageName)) {
return true;
}
return false;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: shouldAutoLaunchSingleChoice
File: core/java/com/android/internal/app/ChooserActivity.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-254",
"CWE-19"
] |
CVE-2016-3752
|
HIGH
| 7.5
|
android
|
shouldAutoLaunchSingleChoice
|
core/java/com/android/internal/app/ChooserActivity.java
|
ddbf2db5b946be8fdc45c7b0327bf560b2a06988
| 0
|
Analyze the following code function for security vulnerabilities
|
@NonNull
public static CallStyle forScreeningCall(@NonNull Person person,
@NonNull PendingIntent hangUpIntent, @NonNull PendingIntent answerIntent) {
return new CallStyle(CALL_TYPE_SCREENING, person,
requireNonNull(hangUpIntent, "hangUpIntent is required"),
null /* declineIntent */,
requireNonNull(answerIntent, "answerIntent is required")
);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: forScreeningCall
File: core/java/android/app/Notification.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-862"
] |
CVE-2023-21288
|
MEDIUM
| 5.5
|
android
|
forScreeningCall
|
core/java/android/app/Notification.java
|
726247f4f53e8cc0746175265652fa415a123c0c
| 0
|
Analyze the following code function for security vulnerabilities
|
private void retryDecryption(Message message) {
message.setEncryption(Message.ENCRYPTION_PGP);
activity.onConversationsListItemUpdated();
refresh();
conversation.getAccount().getPgpDecryptionService().decrypt(message, false);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: retryDecryption
File: src/main/java/eu/siacs/conversations/ui/ConversationFragment.java
Repository: iNPUTmice/Conversations
The code follows secure coding practices.
|
[
"CWE-200"
] |
CVE-2018-18467
|
MEDIUM
| 5
|
iNPUTmice/Conversations
|
retryDecryption
|
src/main/java/eu/siacs/conversations/ui/ConversationFragment.java
|
7177c523a1b31988666b9337249a4f1d0c36f479
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
void removeChild(WindowState child) {
if (!mChildren.contains(child)) {
// This can be true when testing.
return;
}
super.removeChild(child);
checkKeyguardFlagsChanged();
updateLetterboxSurface(child);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: removeChild
File: services/core/java/com/android/server/wm/ActivityRecord.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2023-21145
|
HIGH
| 7.8
|
android
|
removeChild
|
services/core/java/com/android/server/wm/ActivityRecord.java
|
44aeef1b82ecf21187d4903c9e3666a118bdeaf3
| 0
|
Analyze the following code function for security vulnerabilities
|
static Entity checkPageOfEntity(ID user, String entity, HttpServletResponse response) throws IOException {
if (!MetadataHelper.containsEntity(entity)) {
response.sendError(404);
return null;
}
final Entity checkEntity = MetadataHelper.getEntity(entity);
if (MetadataHelper.getEntityType(checkEntity) == MetadataHelper.TYPE_SYS) {
response.sendError(404);
return null;
}
if (!Application.getPrivilegesManager().allowRead(user, checkEntity.getEntityCode())) {
response.sendError(403, Language.L("你没有访问此页面的权限"));
return null;
}
return checkEntity;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: checkPageOfEntity
File: src/main/java/com/rebuild/web/general/GeneralListController.java
Repository: getrebuild/rebuild
The code follows secure coding practices.
|
[
"CWE-89"
] |
CVE-2023-1495
|
MEDIUM
| 6.5
|
getrebuild/rebuild
|
checkPageOfEntity
|
src/main/java/com/rebuild/web/general/GeneralListController.java
|
c9474f84e5f376dd2ade2078e3039961a9425da7
| 0
|
Analyze the following code function for security vulnerabilities
|
public String[] getPackagesToScan() {
return this.packagesToScan;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getPackagesToScan
File: spring-oxm/src/main/java/org/springframework/oxm/jaxb/Jaxb2Marshaller.java
Repository: spring-projects/spring-framework
The code follows secure coding practices.
|
[
"CWE-264"
] |
CVE-2013-4152
|
MEDIUM
| 6.8
|
spring-projects/spring-framework
|
getPackagesToScan
|
spring-oxm/src/main/java/org/springframework/oxm/jaxb/Jaxb2Marshaller.java
|
2843b7d2ee12e3f9c458f6f816befd21b402e3b9
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public String getJMSType() throws JMSException {
return this.getStringProperty(JMS_MESSAGE_TYPE);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getJMSType
File: src/main/java/com/rabbitmq/jms/client/RMQMessage.java
Repository: rabbitmq/rabbitmq-jms-client
The code follows secure coding practices.
|
[
"CWE-502"
] |
CVE-2020-36282
|
HIGH
| 7.5
|
rabbitmq/rabbitmq-jms-client
|
getJMSType
|
src/main/java/com/rabbitmq/jms/client/RMQMessage.java
|
f647e5dbfe055a2ca8cbb16dd70f9d50d888b638
| 0
|
Analyze the following code function for security vulnerabilities
|
public IRemoteAnimationRunner getUnoccludeAnimationRunner() {
return mUnoccludeAnimationRunner;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getUnoccludeAnimationRunner
File: packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2023-21267
|
MEDIUM
| 5.5
|
android
|
getUnoccludeAnimationRunner
|
packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java
|
d18d8b350756b0e89e051736c1f28744ed31e93a
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public Handler<ServerWebSocket> webSocketHandler() {
if (!options.isWebsocketBridge()) {
return null;
}
StompServerHandler stomp;
synchronized (this) {
stomp = this.handler;
}
return socket -> {
if (!socket.path().equals(options.getWebsocketPath())) {
LOGGER.error("Receiving a web socket connection on an invalid path (" + socket.path() + "), the path is " +
"configured to " + options.getWebsocketPath() + ". Rejecting connection");
socket.reject();
return;
}
StompServerConnection connection = new StompServerWebSocketConnectionImpl(socket, this, writingFrameHandler);
FrameParser parser = new FrameParser(options);
socket.exceptionHandler((exception) -> {
LOGGER.error("The STOMP server caught a WebSocket error - closing connection", exception);
connection.close();
});
socket.endHandler(v -> connection.close());
parser
.errorHandler((exception) -> {
connection.write(
Frames.createInvalidFrameErrorFrame(exception));
connection.close();
}
)
.handler(frame -> stomp.handle(new ServerFrameImpl(frame, connection)));
socket.handler(parser);
};
}
|
Vulnerability Classification:
- CWE: CWE-287
- CVE: CVE-2023-32081
- Severity: MEDIUM
- CVSS Score: 6.5
Description: STOMP server process client frames that would not send initially a connect frame
A Vert.x STOMP server processes client STOMP frames without checking that the client send an initial CONNECT frame replied with a successful CONNECTED frame. The client can subscribe to a destination or publish message without prior authentication. Any Vert.x STOMP server configured with an authentication handler is impacted.
Fixes CVE-2023-32081
Function: webSocketHandler
File: src/main/java/io/vertx/ext/stomp/impl/StompServerImpl.java
Repository: vert-x3/vertx-stomp
Fixed Code:
@Override
public Handler<ServerWebSocket> webSocketHandler() {
if (!options.isWebsocketBridge()) {
return null;
}
StompServerHandler stomp;
synchronized (this) {
stomp = this.handler;
}
return socket -> {
if (!socket.path().equals(options.getWebsocketPath())) {
LOGGER.error("Receiving a web socket connection on an invalid path (" + socket.path() + "), the path is " +
"configured to " + options.getWebsocketPath() + ". Rejecting connection");
socket.reject();
return;
}
AtomicBoolean connected = new AtomicBoolean();
AtomicBoolean firstFrame = new AtomicBoolean();
StompServerConnection connection = new StompServerWebSocketConnectionImpl(socket, this, frame -> {
if (frame.frame().getCommand() == Command.CONNECTED || frame.frame().getCommand() == Command.STOMP) {
connected.set(true);
}
Handler<ServerFrame> h = writingFrameHandler;
if (h != null) {
h.handle(frame);
}
});
FrameParser parser = new FrameParser(options);
socket.exceptionHandler((exception) -> {
LOGGER.error("The STOMP server caught a WebSocket error - closing connection", exception);
connection.close();
});
socket.endHandler(v -> connection.close());
parser
.errorHandler((exception) -> {
connection.write(
Frames.createInvalidFrameErrorFrame(exception));
connection.close();
}
)
.handler(frame -> {
if (frame.getCommand() == Command.CONNECT) {
if (firstFrame.compareAndSet(false, true)) {
stomp.handle(new ServerFrameImpl(frame, connection));
} else {
connection.write(Frames.createErrorFrame("Already connected", Collections.emptyMap(), ""));
connection.close();
}
} else if (connected.get()) {
stomp.handle(new ServerFrameImpl(frame, connection));
} else {
connection.write(Frames.createErrorFrame("Not connected", Collections.emptyMap(), ""));
connection.close();
}
});
socket.handler(parser);
};
}
|
[
"CWE-287"
] |
CVE-2023-32081
|
MEDIUM
| 6.5
|
vert-x3/vertx-stomp
|
webSocketHandler
|
src/main/java/io/vertx/ext/stomp/impl/StompServerImpl.java
|
0de4bc5a44ddb57e74d92c445f16456fa03f265b
| 1
|
Analyze the following code function for security vulnerabilities
|
public void setExposedGuts(NotificationGuts guts) {
mNotificationGutsExposed = guts;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: setExposedGuts
File: packages/SystemUI/src/com/android/systemui/statusbar/notification/row/NotificationGutsManager.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2023-40098
|
MEDIUM
| 5.5
|
android
|
setExposedGuts
|
packages/SystemUI/src/com/android/systemui/statusbar/notification/row/NotificationGutsManager.java
|
d21ffbe8a2eeb2a5e6da7efbb1a0430ba6b022e0
| 0
|
Analyze the following code function for security vulnerabilities
|
public void setDockerImage(String dockerImage) {
this.dockerImage = dockerImage;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: setDockerImage
File: server-plugin/server-plugin-executor-serverdocker/src/main/java/io/onedev/server/plugin/executor/serverdocker/ServerDockerExecutor.java
Repository: theonedev/onedev
The code follows secure coding practices.
|
[
"CWE-610"
] |
CVE-2022-39206
|
CRITICAL
| 9.9
|
theonedev/onedev
|
setDockerImage
|
server-plugin/server-plugin-executor-serverdocker/src/main/java/io/onedev/server/plugin/executor/serverdocker/ServerDockerExecutor.java
|
0052047a5b5095ac6a6b4a73a522d0272fec3a22
| 0
|
Analyze the following code function for security vulnerabilities
|
protected Http2PromisedRequestVerifier promisedRequestVerifier() {
return promisedRequestVerifier;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: promisedRequestVerifier
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
|
promisedRequestVerifier
|
codec-http2/src/main/java/io/netty/handler/codec/http2/AbstractHttp2ConnectionHandlerBuilder.java
|
58f75f665aa81a8cbcf6ffa74820042a285c5e61
| 0
|
Analyze the following code function for security vulnerabilities
|
private static boolean isValidTouchEventActionForNative(int eventAction) {
// Only these actions have any effect on gesture detection. Other
// actions have no corresponding WebTouchEvent type and may confuse the
// touch pipline, so we ignore them entirely.
return eventAction == MotionEvent.ACTION_DOWN
|| eventAction == MotionEvent.ACTION_UP
|| eventAction == MotionEvent.ACTION_CANCEL
|| eventAction == MotionEvent.ACTION_MOVE
|| eventAction == MotionEvent.ACTION_POINTER_DOWN
|| eventAction == MotionEvent.ACTION_POINTER_UP;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: isValidTouchEventActionForNative
File: content/public/android/java/src/org/chromium/content/browser/ContentViewCore.java
Repository: chromium
The code follows secure coding practices.
|
[
"CWE-1021"
] |
CVE-2015-1241
|
MEDIUM
| 4.3
|
chromium
|
isValidTouchEventActionForNative
|
content/public/android/java/src/org/chromium/content/browser/ContentViewCore.java
|
9d343ad2ea6ec395c377a4efa266057155bfa9c1
| 0
|
Analyze the following code function for security vulnerabilities
|
@NonNull
public Builder setVisibility(@Visibility int visibility) {
mN.visibility = visibility;
return this;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: setVisibility
File: core/java/android/app/Notification.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-862"
] |
CVE-2023-21288
|
MEDIUM
| 5.5
|
android
|
setVisibility
|
core/java/android/app/Notification.java
|
726247f4f53e8cc0746175265652fa415a123c0c
| 0
|
Analyze the following code function for security vulnerabilities
|
private void saveRunningDevServerPort() {
try {
FileUtils.writeStringToFile(devServerPortFile, String.valueOf(port),
StandardCharsets.UTF_8);
} catch (IOException e) {
throw new UncheckedIOException(e);
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: saveRunningDevServerPort
File: flow-server/src/main/java/com/vaadin/flow/server/DevModeHandler.java
Repository: vaadin/flow
The code follows secure coding practices.
|
[
"CWE-22"
] |
CVE-2020-36321
|
MEDIUM
| 5
|
vaadin/flow
|
saveRunningDevServerPort
|
flow-server/src/main/java/com/vaadin/flow/server/DevModeHandler.java
|
6ae6460ca4f3a9b50bd46fbf49c807fe67718307
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public String getServerName() {
return null;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getServerName
File: h2/src/test/org/h2/test/server/TestWeb.java
Repository: h2database
The code follows secure coding practices.
|
[
"CWE-312"
] |
CVE-2022-45868
|
HIGH
| 7.8
|
h2database
|
getServerName
|
h2/src/test/org/h2/test/server/TestWeb.java
|
23ee3d0b973923c135fa01356c8eaed40b895393
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
super.onInitializeAccessibilityEvent(event);
if (mGutsContainer != null &&
event.getEventType() == AccessibilityEvent.TYPE_WINDOW_STATE_CHANGED) {
if (mGutsContainer.isExposed()) {
event.getText().add(mContext.getString(
R.string.notification_channel_controls_opened_accessibility, mAppName));
} else {
event.getText().add(mContext.getString(
R.string.notification_channel_controls_closed_accessibility, mAppName));
}
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: onInitializeAccessibilityEvent
File: packages/SystemUI/src/com/android/systemui/statusbar/notification/row/NotificationConversationInfo.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2023-40098
|
MEDIUM
| 5.5
|
android
|
onInitializeAccessibilityEvent
|
packages/SystemUI/src/com/android/systemui/statusbar/notification/row/NotificationConversationInfo.java
|
d21ffbe8a2eeb2a5e6da7efbb1a0430ba6b022e0
| 0
|
Analyze the following code function for security vulnerabilities
|
@HotPath(caller = HotPath.START_SERVICE)
boolean hasActiveVisibleWindow(int uid) {
if (mVisibleActivityProcessTracker.hasVisibleActivity(uid)) {
return true;
}
return mActiveUids.hasNonAppVisibleWindow(uid);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: hasActiveVisibleWindow
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
|
hasActiveVisibleWindow
|
services/core/java/com/android/server/wm/ActivityTaskManagerService.java
|
1120bc7e511710b1b774adf29ba47106292365e7
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public boolean isPackageAllowedToAccessCalendarForUser(String packageName,
@UserIdInt int userId) {
if (!mHasFeature) {
return false;
}
Preconditions.checkStringNotEmpty(packageName, "Package name is null or empty");
Preconditions.checkArgumentNonnegative(userId, "Invalid userId");
final int packageUid;
try (var snapshot = mInjector.getPackageManagerLocal().withUnfilteredSnapshot()) {
var packageState = snapshot.getPackageStates().get(packageName);
if (packageState == null) {
Slogf.w(LOG_TAG, "Couldn't find package %s in user %d", packageName,
userId);
return false;
} else if (!packageState.getUserStateOrDefault(userId).isInstalled()) {
Slogf.w(LOG_TAG, "Couldn't find installed package %s in user %d", packageName,
userId);
return false;
} else {
packageUid = UserHandle.getUid(userId, packageState.getAppId());
}
}
final CallerIdentity caller = getCallerIdentity();
if (caller.getUid() != packageUid) {
Preconditions.checkCallAuthorization(
hasCallingOrSelfPermission(permission.INTERACT_ACROSS_USERS)
|| hasCallingOrSelfPermission(permission.INTERACT_ACROSS_USERS_FULL));
}
synchronized (getLockObject()) {
if (mInjector.settingsSecureGetIntForUser(
Settings.Secure.CROSS_PROFILE_CALENDAR_ENABLED, 0, userId) == 0) {
return false;
}
final ActiveAdmin admin = getProfileOwnerAdminLocked(userId);
if (admin != null) {
if (admin.mCrossProfileCalendarPackages == null) {
return true;
}
return admin.mCrossProfileCalendarPackages.contains(packageName);
}
}
return false;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: isPackageAllowedToAccessCalendarForUser
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
|
isPackageAllowedToAccessCalendarForUser
|
services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
|
e2e05f488da6abc765a62e7faf10cb74e729732e
| 0
|
Analyze the following code function for security vulnerabilities
|
public boolean param(HttpServletRequest req, String param) {
return req.getParameter(param) != null;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: param
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
|
param
|
src/main/java/com/erudika/scoold/utils/ScooldUtils.java
|
62a0e92e1486ddc17676a7ead2c07ff653d167ce
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public String getLocalAddr() {
return null;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getLocalAddr
File: h2/src/test/org/h2/test/server/TestWeb.java
Repository: h2database
The code follows secure coding practices.
|
[
"CWE-312"
] |
CVE-2022-45868
|
HIGH
| 7.8
|
h2database
|
getLocalAddr
|
h2/src/test/org/h2/test/server/TestWeb.java
|
23ee3d0b973923c135fa01356c8eaed40b895393
| 0
|
Analyze the following code function for security vulnerabilities
|
@HotPath(caller = HotPath.OOM_ADJUSTMENT)
@Override
public WindowProcessController getTopApp() {
return mTopApp;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getTopApp
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
|
getTopApp
|
services/core/java/com/android/server/wm/ActivityTaskManagerService.java
|
1120bc7e511710b1b774adf29ba47106292365e7
| 0
|
Analyze the following code function for security vulnerabilities
|
public static Object getDefaultAttribute(Channel channel) {
Attribute<Object> attr = channel.attr(DEFAULT_ATTRIBUTE);
return attr != null ? attr.get() : null;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getDefaultAttribute
File: providers/netty/src/main/java/org/asynchttpclient/providers/netty/channel/Channels.java
Repository: AsyncHttpClient/async-http-client
The code follows secure coding practices.
|
[
"CWE-345"
] |
CVE-2013-7397
|
MEDIUM
| 4.3
|
AsyncHttpClient/async-http-client
|
getDefaultAttribute
|
providers/netty/src/main/java/org/asynchttpclient/providers/netty/channel/Channels.java
|
df6ed70e86c8fc340ed75563e016c8baa94d7e72
| 0
|
Analyze the following code function for security vulnerabilities
|
@Test(description = "Test searching a package from central", dependsOnMethods = "testPush")
public void testSearch() throws BallerinaTestException {
String actualMsg = balClient.runMainAndReadStdOut("search", new String[]{moduleName}, envVariables,
balServer.getServerHome(), false);
// Check if the search results contains the following.
Assert.assertTrue(actualMsg.contains("Ballerina Central"));
Assert.assertTrue(actualMsg.contains("NAME"));
Assert.assertTrue(actualMsg.contains("DESCRIPTION"));
Assert.assertTrue(actualMsg.contains("DATE"));
Assert.assertTrue(actualMsg.contains("VERSION"));
Assert.assertTrue(actualMsg.contains(datePushed));
Assert.assertTrue(actualMsg.contains("0.1.0"));
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: testSearch
File: tests/jballerina-integration-test/src/test/java/org/ballerinalang/test/packaging/PackagingTestCase.java
Repository: ballerina-platform/ballerina-lang
The code follows secure coding practices.
|
[
"CWE-306"
] |
CVE-2021-32700
|
MEDIUM
| 5.8
|
ballerina-platform/ballerina-lang
|
testSearch
|
tests/jballerina-integration-test/src/test/java/org/ballerinalang/test/packaging/PackagingTestCase.java
|
4609ffee1744ecd16aac09303b1783bf0a525816
| 0
|
Analyze the following code function for security vulnerabilities
|
protected void
postParse(Ruby runtime, IRubyObject handlerRuby, NokogiriHandler handler)
{
// noop
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: postParse
File: ext/java/nokogiri/XmlSaxParserContext.java
Repository: sparklemotion/nokogiri
The code follows secure coding practices.
|
[
"CWE-241"
] |
CVE-2022-29181
|
MEDIUM
| 6.4
|
sparklemotion/nokogiri
|
postParse
|
ext/java/nokogiri/XmlSaxParserContext.java
|
db05ba9a1bd4b90aa6c76742cf6102a7c7297267
| 0
|
Analyze the following code function for security vulnerabilities
|
byte[] toHash(String credential, int userId);
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: toHash
File: services/core/java/com/android/server/LockSettingsService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-255"
] |
CVE-2016-3749
|
MEDIUM
| 4.6
|
android
|
toHash
|
services/core/java/com/android/server/LockSettingsService.java
|
e83f0f6a5a6f35323f5367f99c8e287c440f33f5
| 0
|
Analyze the following code function for security vulnerabilities
|
public void setAllowPing(Integer allowPing) {
this.allowPing = allowPing;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: setAllowPing
File: src/main/java/cn/luischen/model/ContentDomain.java
Repository: WinterChenS/my-site
The code follows secure coding practices.
|
[
"CWE-79"
] |
CVE-2023-29638
|
MEDIUM
| 5.4
|
WinterChenS/my-site
|
setAllowPing
|
src/main/java/cn/luischen/model/ContentDomain.java
|
d104f38aaae2f1b76c33fadfcf6b1ef1c6c340ed
| 0
|
Analyze the following code function for security vulnerabilities
|
public void init(AsymmetricKeyParameter publicKey, CipherParameters params, EphemeralKeyPairGenerator ephemeralKeyPairGenerator)
{
this.forEncryption = true;
this.pubParam = publicKey;
this.keyPairGenerator = ephemeralKeyPairGenerator;
extractParams(params);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: init
File: core/src/main/java/org/bouncycastle/crypto/engines/IESEngine.java
Repository: bcgit/bc-java
The code follows secure coding practices.
|
[
"CWE-361"
] |
CVE-2016-1000345
|
MEDIUM
| 4.3
|
bcgit/bc-java
|
init
|
core/src/main/java/org/bouncycastle/crypto/engines/IESEngine.java
|
21dcb3d9744c83dcf2ff8fcee06dbca7bfa4ef35
| 0
|
Analyze the following code function for security vulnerabilities
|
private void removeTasksByPackageNameLocked(String packageName, int userId) {
// Remove all tasks with activities in the specified package from the list of recent tasks
for (int i = mRecentTasks.size() - 1; i >= 0; i--) {
TaskRecord tr = mRecentTasks.get(i);
if (tr.userId != userId) continue;
ComponentName cn = tr.intent.getComponent();
if (cn != null && cn.getPackageName().equals(packageName)) {
// If the package name matches, remove the task.
removeTaskByIdLocked(tr.taskId, true, REMOVE_FROM_RECENTS);
}
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: removeTasksByPackageNameLocked
File: services/core/java/com/android/server/am/ActivityManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-264"
] |
CVE-2016-3912
|
HIGH
| 9.3
|
android
|
removeTasksByPackageNameLocked
|
services/core/java/com/android/server/am/ActivityManagerService.java
|
6c049120c2d749f0c0289d822ec7d0aa692f55c5
| 0
|
Analyze the following code function for security vulnerabilities
|
public void scale(Object nativeGraphics, float x, float y) {
((AndroidGraphics) nativeGraphics).scale(x, y);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: scale
File: Ports/Android/src/com/codename1/impl/android/AndroidImplementation.java
Repository: codenameone/CodenameOne
The code follows secure coding practices.
|
[
"CWE-668"
] |
CVE-2022-4903
|
MEDIUM
| 5.1
|
codenameone/CodenameOne
|
scale
|
Ports/Android/src/com/codename1/impl/android/AndroidImplementation.java
|
dad49c9ef26a598619fc48d2697151a02987d478
| 0
|
Analyze the following code function for security vulnerabilities
|
@PipelineProperty(description = "The text converter configuration that should be used to parse the input data.")
@PipelinePropertyDocRef(types=TextConverter.ENTITY_TYPE)
public void setTextConverter(final DocRef textConverterRef) {
this.textConverterRef = textConverterRef;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: setTextConverter
File: stroom-pipeline/src/main/java/stroom/pipeline/server/parser/CombinedParser.java
Repository: gchq/stroom
The code follows secure coding practices.
|
[
"CWE-611"
] |
CVE-2018-1000651
|
HIGH
| 7.5
|
gchq/stroom
|
setTextConverter
|
stroom-pipeline/src/main/java/stroom/pipeline/server/parser/CombinedParser.java
|
ba30ffd415bd7d32ee40ba4b04035267ce80b499
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public boolean isTopOfTask(IBinder token) {
return ActivityClient.getInstance().isTopOfTask(token);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: isTopOfTask
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
|
isTopOfTask
|
services/core/java/com/android/server/am/ActivityManagerService.java
|
d10b27e539f7bc91c2360d429b9d05f05274670d
| 0
|
Analyze the following code function for security vulnerabilities
|
@Nullable
private MacAddress retrieveFactoryMacAddressAndStoreIfNecessary() {
boolean saveFactoryMacInConfigStore =
mWifiGlobals.isSaveFactoryMacToConfigStoreEnabled();
if (saveFactoryMacInConfigStore) {
// Already present, just return.
String factoryMacAddressStr = mSettingsConfigStore.get(WIFI_STA_FACTORY_MAC_ADDRESS);
if (factoryMacAddressStr != null) return MacAddress.fromString(factoryMacAddressStr);
}
MacAddress factoryMacAddress = mWifiNative.getStaFactoryMacAddress(mInterfaceName);
if (factoryMacAddress == null) {
// the device may be running an older HAL (version < 1.3).
Log.w(TAG, "Failed to retrieve factory MAC address");
return null;
}
if (saveFactoryMacInConfigStore) {
mSettingsConfigStore.put(WIFI_STA_FACTORY_MAC_ADDRESS, factoryMacAddress.toString());
Log.i(TAG, "Factory MAC address stored in config store: " + factoryMacAddress);
}
Log.i(TAG, "Factory MAC address retrieved: " + factoryMacAddress);
return factoryMacAddress;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: retrieveFactoryMacAddressAndStoreIfNecessary
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
|
retrieveFactoryMacAddressAndStoreIfNecessary
|
service/java/com/android/server/wifi/ClientModeImpl.java
|
72e903f258b5040b8f492cf18edd124b5a1ac770
| 0
|
Analyze the following code function for security vulnerabilities
|
@Transactional
@Listen
public void on(EntityPersisted event) {
if (event.getEntity() instanceof Project) {
ProjectFacade facade = ((Project) event.getEntity()).getFacade();
transactionManager.runAfterCommit(new Runnable() {
@Override
public void run() {
cacheLock.writeLock().lock();
try {
cache.put(facade.getId(), facade);
} finally {
cacheLock.writeLock().unlock();
}
}
});
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: on
File: server-core/src/main/java/io/onedev/server/entitymanager/impl/DefaultProjectManager.java
Repository: theonedev/onedev
The code follows secure coding practices.
|
[
"CWE-287"
] |
CVE-2022-39205
|
CRITICAL
| 9.8
|
theonedev/onedev
|
on
|
server-core/src/main/java/io/onedev/server/entitymanager/impl/DefaultProjectManager.java
|
f1e97688e4e19d6de1dfa1d00e04655209d39f8e
| 0
|
Analyze the following code function for security vulnerabilities
|
private void updateFontWeightAdjustmentIfNeeded(@UserIdInt int userId) {
if (userId != getCurrentUserId()) {
return;
}
final int fontWeightAdjustment =
Settings.Secure.getIntForUser(
mContext.getContentResolver(),
Settings.Secure.FONT_WEIGHT_ADJUSTMENT,
Configuration.FONT_WEIGHT_ADJUSTMENT_UNDEFINED,
userId);
synchronized (mGlobalLock) {
if (getGlobalConfiguration().fontWeightAdjustment == fontWeightAdjustment) {
return;
}
final Configuration configuration =
mWindowManager.computeNewConfiguration(DEFAULT_DISPLAY);
configuration.fontWeightAdjustment = fontWeightAdjustment;
updatePersistentConfiguration(configuration, userId);
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: updateFontWeightAdjustmentIfNeeded
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
|
updateFontWeightAdjustmentIfNeeded
|
services/core/java/com/android/server/wm/ActivityTaskManagerService.java
|
1120bc7e511710b1b774adf29ba47106292365e7
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public boolean hasDeviceOwner() {
final CallerIdentity caller = getCallerIdentity();
Preconditions.checkCallAuthorization(isDefaultDeviceOwner(caller)
|| canManageUsers(caller) || isFinancedDeviceOwner(caller)
|| hasCallingOrSelfPermission(permission.MANAGE_PROFILE_AND_DEVICE_OWNERS));
return mOwners.hasDeviceOwner();
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: hasDeviceOwner
File: services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-20"
] |
CVE-2023-21284
|
MEDIUM
| 5.5
|
android
|
hasDeviceOwner
|
services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
|
ed3f25b7222d4cff471f2b7d22d1150348146957
| 0
|
Analyze the following code function for security vulnerabilities
|
public Builder setCredentialCreatedListener(
CredentialCreatedListener credentialCreatedListener) {
this.credentialCreatedListener = credentialCreatedListener;
return this;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: setCredentialCreatedListener
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
|
setCredentialCreatedListener
|
google-oauth-client/src/main/java/com/google/api/client/auth/oauth2/AuthorizationCodeFlow.java
|
13433cd7dd06267fc261f0b1d4764f8e3432c824
| 0
|
Analyze the following code function for security vulnerabilities
|
@GuardedBy("this")
final void appDiedLocked(ProcessRecord app, int pid, IApplicationThread thread,
boolean fromBinderDied, String reason) {
// First check if this ProcessRecord is actually active for the pid.
final ProcessRecord curProc;
synchronized (mPidsSelfLocked) {
curProc = mPidsSelfLocked.get(pid);
}
if (curProc != app) {
if (!fromBinderDied || !mProcessList.handleDyingAppDeathLocked(app, pid)) {
Slog.w(TAG, "Spurious death for " + app + ", curProc for " + pid + ": " + curProc);
}
return;
}
mBatteryStatsService.noteProcessDied(app.info.uid, pid);
if (!app.isKilled()) {
if (!fromBinderDied) {
killProcessQuiet(pid);
mProcessList.noteAppKill(app, ApplicationExitInfo.REASON_OTHER,
ApplicationExitInfo.SUBREASON_UNKNOWN, reason);
}
ProcessList.killProcessGroup(app.uid, pid);
synchronized (mProcLock) {
app.setKilled(true);
}
}
// Clean up already done if the process has been re-started.
IApplicationThread appThread;
final int setAdj = app.mState.getSetAdj();
final int setProcState = app.mState.getSetProcState();
if (app.getPid() == pid && (appThread = app.getThread()) != null
&& appThread.asBinder() == thread.asBinder()) {
boolean doLowMem = app.getActiveInstrumentation() == null;
boolean doOomAdj = doLowMem;
if (!app.isKilledByAm()) {
reportUidInfoMessageLocked(TAG,
"Process " + app.processName + " (pid " + pid + ") has died: "
+ ProcessList.makeOomAdjString(setAdj, true) + " "
+ ProcessList.makeProcStateString(setProcState), app.info.uid);
mAppProfiler.setAllowLowerMemLevelLocked(true);
} else {
// Note that we always want to do oom adj to update our state with the
// new number of procs.
mAppProfiler.setAllowLowerMemLevelLocked(false);
doLowMem = false;
}
EventLogTags.writeAmProcDied(app.userId, pid, app.processName, setAdj, setProcState);
if (DEBUG_CLEANUP) Slog.v(TAG_CLEANUP,
"Dying app: " + app + ", pid: " + pid + ", thread: " + thread.asBinder());
handleAppDiedLocked(app, pid, false, true, fromBinderDied);
if (doOomAdj) {
updateOomAdjLocked(OomAdjuster.OOM_ADJ_REASON_PROCESS_END);
}
if (doLowMem) {
mAppProfiler.doLowMemReportIfNeededLocked(app);
}
} else if (app.getPid() != pid) {
// A new process has already been started.
reportUidInfoMessageLocked(TAG,
"Process " + app.processName + " (pid " + pid
+ ") has died and restarted (pid " + app.getPid() + ").", app.info.uid);
EventLogTags.writeAmProcDied(app.userId, app.getPid(), app.processName,
setAdj, setProcState);
} else if (DEBUG_PROCESSES) {
Slog.d(TAG_PROCESSES, "Received spurious death notification for thread "
+ thread.asBinder());
}
// On the device which doesn't have Cgroup, log LmkStateChanged which is used as a signal
// for pulling memory stats of other running processes when this process died.
if (!hasMemcg()) {
FrameworkStatsLog.write(FrameworkStatsLog.APP_DIED, SystemClock.elapsedRealtime());
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: appDiedLocked
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
|
appDiedLocked
|
services/core/java/com/android/server/am/ActivityManagerService.java
|
d10b27e539f7bc91c2360d429b9d05f05274670d
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public boolean runsForever() {
return false;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: runsForever
File: graylog2-server/src/main/java/org/graylog2/events/ClusterEventPeriodical.java
Repository: Graylog2/graylog2-server
The code follows secure coding practices.
|
[
"CWE-863"
] |
CVE-2024-24824
|
HIGH
| 8.8
|
Graylog2/graylog2-server
|
runsForever
|
graylog2-server/src/main/java/org/graylog2/events/ClusterEventPeriodical.java
|
75ef2b8d60e7d67f859b79fe712c8ae7b2e861d8
| 0
|
Analyze the following code function for security vulnerabilities
|
public String getSortKey() {
return mSortKey;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getSortKey
File: core/java/android/app/Notification.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-862"
] |
CVE-2023-21288
|
MEDIUM
| 5.5
|
android
|
getSortKey
|
core/java/android/app/Notification.java
|
726247f4f53e8cc0746175265652fa415a123c0c
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public int getPackageScreenCompatMode(String packageName) {
enforceNotIsolatedCaller("getPackageScreenCompatMode");
synchronized (mGlobalLock) {
return mCompatModePackages.getPackageScreenCompatModeLocked(packageName);
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getPackageScreenCompatMode
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
|
getPackageScreenCompatMode
|
services/core/java/com/android/server/wm/ActivityTaskManagerService.java
|
1120bc7e511710b1b774adf29ba47106292365e7
| 0
|
Analyze the following code function for security vulnerabilities
|
private ScanDetailCache getOrCreateScanDetailCacheForNetwork(WifiConfiguration config) {
if (config == null) return null;
ScanDetailCache cache = getScanDetailCacheForNetwork(config.networkId);
if (cache == null && config.networkId != WifiConfiguration.INVALID_NETWORK_ID) {
cache = new ScanDetailCache(
config, SCAN_CACHE_ENTRIES_MAX_SIZE, SCAN_CACHE_ENTRIES_TRIM_SIZE);
mScanDetailCaches.put(config.networkId, cache);
}
return cache;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getOrCreateScanDetailCacheForNetwork
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
|
getOrCreateScanDetailCacheForNetwork
|
service/java/com/android/server/wifi/WifiConfigManager.java
|
72e903f258b5040b8f492cf18edd124b5a1ac770
| 0
|
Analyze the following code function for security vulnerabilities
|
private String userReferenceToString(DocumentReference userReference)
{
String userString;
if (userReference != null) {
userString = getCompactWikiEntityReferenceSerializer().serialize(userReference, getDocumentReference());
} else {
userString = XWikiRightService.GUEST_USER_FULLNAME;
}
return userString;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: userReferenceToString
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
|
userReferenceToString
|
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
|
@Override
public void startShellPermissionIdentityDelegation(int uid, @NonNull String packageName,
@Nullable List<String> permissionNames) {
Objects.requireNonNull(packageName, "packageName");
startShellPermissionIdentityDelegationInternal(uid, packageName, permissionNames);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: startShellPermissionIdentityDelegation
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
|
startShellPermissionIdentityDelegation
|
services/core/java/com/android/server/pm/permission/PermissionManagerService.java
|
c00b7e7dbc1fa30339adef693d02a51254755d7f
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public String getDirectory() {
String path;
if (state.mode == Mode.ADD || state.mode == Mode.EDIT) {
path = getNewPath();
if (path != null) {
if (path.contains("/"))
path = StringUtils.substringBeforeLast(path, "/");
else
path = null;
} else {
throw new IllegalStateException();
}
} else if (state.blobIdent.isTree()) {
path = state.blobIdent.path;
} else if (state.blobIdent.path.contains("/")) {
path = StringUtils.substringBeforeLast(state.blobIdent.path, "/");
} else {
path = null;
}
return path;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getDirectory
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
|
getDirectory
|
server-core/src/main/java/io/onedev/server/web/page/project/blob/ProjectBlobPage.java
|
0c060153fb97c0288a1917efdb17cc426934dacb
| 0
|
Analyze the following code function for security vulnerabilities
|
private boolean isValidationMethod(ResolvedMethod m) {
return m.get(SelfValidation.class) != null;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: isValidationMethod
File: dropwizard-validation/src/main/java/io/dropwizard/validation/selfvalidating/SelfValidatingValidator.java
Repository: dropwizard
The code follows secure coding practices.
|
[
"CWE-74"
] |
CVE-2020-11002
|
HIGH
| 9
|
dropwizard
|
isValidationMethod
|
dropwizard-validation/src/main/java/io/dropwizard/validation/selfvalidating/SelfValidatingValidator.java
|
d5a512f7abf965275f2a6b913ac4fe778e424242
| 0
|
Analyze the following code function for security vulnerabilities
|
public void upload(String fileId, MultipartFile file) {
// check if the path is valid (not outside staticDir)
Assert.notNull(file, "Multipart file must not be null");
try {
if (!isImage(file)) {
DEException.throwException("Multipart file must be image");
}
String originName = file.getOriginalFilename();
String newFileName = fileId + originName.substring(originName.lastIndexOf("."), originName.length());
Path uploadPath = Paths.get(staticDir.toString(), newFileName);
// create dir is absent
FileUtils.createIfAbsent(Paths.get(staticDir.toString()));
Files.createFile(uploadPath);
file.transferTo(uploadPath);
} catch (IOException e) {
LogUtil.error("文件上传失败", e);
DataEaseException.throwException("文件上传失败");
} catch (Exception e) {
DataEaseException.throwException(e);
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: upload
File: core/backend/src/main/java/io/dataease/service/staticResource/StaticResourceService.java
Repository: dataease
The code follows secure coding practices.
|
[
"CWE-434"
] |
CVE-2023-40183
|
MEDIUM
| 5.3
|
dataease
|
upload
|
core/backend/src/main/java/io/dataease/service/staticResource/StaticResourceService.java
|
826513053146721a2b3e09a9c9d3ea41f8f10569
| 0
|
Analyze the following code function for security vulnerabilities
|
public byte[] getLastReadRawDataCache() {
return lastReadRawDataCache;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getLastReadRawDataCache
File: src/main/java/net/lingala/zip4j/io/inputstream/CipherInputStream.java
Repository: srikanth-lingala/zip4j
The code follows secure coding practices.
|
[
"CWE-346"
] |
CVE-2023-22899
|
MEDIUM
| 5.9
|
srikanth-lingala/zip4j
|
getLastReadRawDataCache
|
src/main/java/net/lingala/zip4j/io/inputstream/CipherInputStream.java
|
ddd8fdc8ad0583eb4a6172dc86c72c881485c55b
| 0
|
Analyze the following code function for security vulnerabilities
|
private void removeTransferSplashScreenTimeout() {
mAtmService.mH.removeCallbacks(mTransferSplashScreenTimeoutRunnable);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: removeTransferSplashScreenTimeout
File: services/core/java/com/android/server/wm/ActivityRecord.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2023-21145
|
HIGH
| 7.8
|
android
|
removeTransferSplashScreenTimeout
|
services/core/java/com/android/server/wm/ActivityRecord.java
|
44aeef1b82ecf21187d4903c9e3666a118bdeaf3
| 0
|
Analyze the following code function for security vulnerabilities
|
public void reportAssistContextExtras(IBinder token, Bundle extras) {
PendingAssistExtras pae = (PendingAssistExtras)token;
synchronized (pae) {
pae.result = extras;
pae.haveResult = true;
pae.notifyAll();
if (pae.intent == null) {
// Caller is just waiting for the result.
return;
}
}
// We are now ready to launch the assist activity.
synchronized (this) {
boolean exists = mPendingAssistExtras.remove(pae);
mHandler.removeCallbacks(pae);
if (!exists) {
// Timed out.
return;
}
}
pae.intent.replaceExtras(extras);
if (pae.hint != null) {
pae.intent.putExtra(pae.hint, true);
}
pae.intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK
| Intent.FLAG_ACTIVITY_SINGLE_TOP
| Intent.FLAG_ACTIVITY_CLEAR_TOP);
closeSystemDialogs("assist");
try {
mContext.startActivityAsUser(pae.intent, new UserHandle(pae.userHandle));
} catch (ActivityNotFoundException e) {
Slog.w(TAG, "No activity to handle assist action.", e);
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: reportAssistContextExtras
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
|
reportAssistContextExtras
|
services/core/java/com/android/server/am/ActivityManagerService.java
|
aaa0fee0d7a8da347a0c47cef5249c70efee209e
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public void configPlugin(Plugins plugins) {
// 如果没有安装的情况下不初始化数据
if (isInstalled()) {
if (StringUtils.isNotEmpty(ZrLogUtil.getDbInfoByEnv())) {
IOUtil.writeBytesToFile(ZrLogUtil.getDbInfoByEnv().getBytes(), new File(getDbProperties()));
}
try (FileInputStream in = new FileInputStream(getDbProperties())) {
dbProperties.load(in);
tryUpgradeDbPropertiesFile(getDbProperties(), dbProperties);
tryDoUpgrade(getUpgradeSqlBasePath(), dbProperties.getProperty("jdbcUrl"), dbProperties.getProperty("user"),
dbProperties.getProperty("password"), dbProperties.getProperty("driverClass"));
jdbcUrl = dbProperties.getProperty("jdbcUrl");
// 启动时候进行数据库连接
HikariCpPlugin dataSourcePlugin = new HikariCpPlugin(dbProperties.getProperty("jdbcUrl"),
dbProperties.getProperty("user"), dbProperties.getProperty("password"));
plugins.add(dataSourcePlugin);
// 添加表与实体的映射关系
plugins.add(getActiveRecordPlugin(dataSourcePlugin));
Object pluginJvmArgsObj = blogProperties.get("pluginJvmArgs");
if (pluginJvmArgsObj == null) {
pluginJvmArgsObj = "";
}
if (!isTest()) {
//这里使用独立的线程进行启动,主要是为了防止插件服务出问题后,影响整体,同时是避免启动过慢的问题。
plugins.add(new PluginCorePlugin(getDbProperties(), pluginJvmArgsObj.toString()));
plugins.add(new UpdateVersionPlugin());
plugins.add(new CacheCleanerPlugin());
}
plugins.add(new RequestStatisticsPlugin());
} catch (Exception e) {
LOGGER.warn("configPlugin exception ", e);
}
} else {
LOGGER.warn("Not found lock file(" + PathKit.getWebRootPath() + "/WEB-INF/install.lock), Please visit the http://yourHostName:port" + JFinal.me().getContextPath() + "/install start installation");
}
JFinal.me().getServletContext().setAttribute("plugins", plugins);
this.plugins = plugins;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: configPlugin
File: web/src/main/java/com/zrlog/web/config/ZrLogConfig.java
Repository: 94fzb/zrlog
The code follows secure coding practices.
|
[
"CWE-79"
] |
CVE-2019-16643
|
LOW
| 3.5
|
94fzb/zrlog
|
configPlugin
|
web/src/main/java/com/zrlog/web/config/ZrLogConfig.java
|
4a91c83af669e31a22297c14f089d8911d353fa1
| 0
|
Analyze the following code function for security vulnerabilities
|
public <T> List<T> search(String sql, Object[][] whereParams, XWikiContext context) throws XWikiException
{
return getStore().search(sql, 0, 0, whereParams, context);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: search
File: xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/XWiki.java
Repository: xwiki/xwiki-platform
The code follows secure coding practices.
|
[
"CWE-863"
] |
CVE-2021-32620
|
MEDIUM
| 4
|
xwiki/xwiki-platform
|
search
|
xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/XWiki.java
|
f9a677408ffb06f309be46ef9d8df1915d9099a4
| 0
|
Analyze the following code function for security vulnerabilities
|
protected Map<String, List<String>> buildResponseHeaders(Response response) {
Map<String, List<String>> responseHeaders = new HashMap<String, List<String>>();
for (Entry<String, List<Object>> entry: response.getHeaders().entrySet()) {
List<Object> values = entry.getValue();
List<String> headers = new ArrayList<String>();
for (Object o : values) {
headers.add(String.valueOf(o));
}
responseHeaders.put(entry.getKey(), headers);
}
return responseHeaders;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: buildResponseHeaders
File: samples/client/petstore/java/okhttp-gson-dynamicOperations/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
|
buildResponseHeaders
|
samples/client/petstore/java/okhttp-gson-dynamicOperations/src/main/java/org/openapitools/client/ApiClient.java
|
2c576483f26f85b3979c6948a131f585c237109a
| 0
|
Analyze the following code function for security vulnerabilities
|
public String[] getGroups() {
return groups;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getGroups
File: src/com/dotmarketing/cache/ContentTypeCacheImpl.java
Repository: dotCMS/core
The code follows secure coding practices.
|
[
"CWE-89"
] |
CVE-2016-2355
|
HIGH
| 7.5
|
dotCMS/core
|
getGroups
|
src/com/dotmarketing/cache/ContentTypeCacheImpl.java
|
897f3632d7e471b7a73aabed5b19f6f53d4e5562
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
protected byte[] engineGetIV() {
return iv;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: engineGetIV
File: src/main/java/org/conscrypt/OpenSSLCipher.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-264"
] |
CVE-2016-2461
|
HIGH
| 7.6
|
android
|
engineGetIV
|
src/main/java/org/conscrypt/OpenSSLCipher.java
|
1638945d4ed9403790962ec7abed1b7a232a9ff8
| 0
|
Analyze the following code function for security vulnerabilities
|
protected List<Service> getServices() {
Service service = currentService.getService();
return (service != null)
? Collections.singletonList(service)
: Collections.emptyList();
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getServices
File: sshd-core/src/main/java/org/apache/sshd/common/session/helpers/AbstractSession.java
Repository: apache/mina-sshd
The code follows secure coding practices.
|
[
"CWE-354"
] |
CVE-2023-48795
|
MEDIUM
| 5.9
|
apache/mina-sshd
|
getServices
|
sshd-core/src/main/java/org/apache/sshd/common/session/helpers/AbstractSession.java
|
6b0fd46f64bcb75eeeee31d65f10242660aad7c1
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
@Nullable
TaskDisplayArea getDisplayArea() {
return (TaskDisplayArea) super.getDisplayArea();
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getDisplayArea
File: services/core/java/com/android/server/wm/ActivityRecord.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-Other"
] |
CVE-2023-21145
|
HIGH
| 7.8
|
android
|
getDisplayArea
|
services/core/java/com/android/server/wm/ActivityRecord.java
|
44aeef1b82ecf21187d4903c9e3666a118bdeaf3
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public boolean isReadTimeoutSupported() {
return true;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: isReadTimeoutSupported
File: Ports/Android/src/com/codename1/impl/android/AndroidImplementation.java
Repository: codenameone/CodenameOne
The code follows secure coding practices.
|
[
"CWE-668"
] |
CVE-2022-4903
|
MEDIUM
| 5.1
|
codenameone/CodenameOne
|
isReadTimeoutSupported
|
Ports/Android/src/com/codename1/impl/android/AndroidImplementation.java
|
dad49c9ef26a598619fc48d2697151a02987d478
| 0
|
Analyze the following code function for security vulnerabilities
|
public void removeRow(ROWTYPE row) {
try {
removeRow(rows.indexOf(row));
} catch (IndexOutOfBoundsException e) {
throw new IllegalArgumentException(
"Section does not contain the given row");
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: removeRow
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
|
removeRow
|
server/src/main/java/com/vaadin/ui/Grid.java
|
b9ba10adaa06a0977c531f878c3f0046b67f9cc0
| 0
|
Analyze the following code function for security vulnerabilities
|
Date getModificationDate(String mediaPackageId) throws NotFoundException, SearchServiceDatabaseException;
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getModificationDate
File: modules/search-service-impl/src/main/java/org/opencastproject/search/impl/persistence/SearchServiceDatabase.java
Repository: opencast
The code follows secure coding practices.
|
[
"CWE-863"
] |
CVE-2021-21318
|
MEDIUM
| 5.5
|
opencast
|
getModificationDate
|
modules/search-service-impl/src/main/java/org/opencastproject/search/impl/persistence/SearchServiceDatabase.java
|
b18c6a7f81f08ed14884592a6c14c9ab611ad450
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public String toString() {
String result = uri.toString() + " [user " + sourceUserId + "]";
if (prefix) result += " [prefix]";
return result;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: toString
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
|
toString
|
services/core/java/com/android/server/am/ActivityManagerService.java
|
962fb40991f15be4f688d960aa00073683ebdd20
| 0
|
Analyze the following code function for security vulnerabilities
|
public static StreamConnection openHdfsInputStream(String urlAddress) throws IOException {
if (!SupportedProtocols.hdfs.isEnabled()) {
throw new MissingDependencyException("Cannot find the HDFS/Hadoop jars in the plugins folder. \n" +
"\nPlease, see the documentation: https://neo4j.com/labs/apoc/4.4/import/web-apis/");
}
return HDFSUtils.readFile(new URL(urlAddress));
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: openHdfsInputStream
File: core/src/main/java/apoc/util/FileUtils.java
Repository: neo4j-contrib/neo4j-apoc-procedures
The code follows secure coding practices.
|
[
"CWE-22"
] |
CVE-2022-23532
|
MEDIUM
| 6.5
|
neo4j-contrib/neo4j-apoc-procedures
|
openHdfsInputStream
|
core/src/main/java/apoc/util/FileUtils.java
|
01e63ed2d187cd2a8aa1d78bf831ef0fdd69b522
| 0
|
Analyze the following code function for security vulnerabilities
|
private static void toArmeria(HttpHeadersBuilder builder, Http2Headers headers, boolean endOfStream) {
builder.sizeHint(headers.size());
builder.endOfStream(endOfStream);
StringJoiner cookieJoiner = null;
for (Entry<CharSequence, CharSequence> e : headers) {
final AsciiString name = HttpHeaderNames.of(e.getKey());
final CharSequence value = e.getValue();
// Cookies must be concatenated into a single octet string.
// https://tools.ietf.org/html/rfc7540#section-8.1.2.5
if (name.equals(HttpHeaderNames.COOKIE)) {
if (cookieJoiner == null) {
cookieJoiner = new StringJoiner(COOKIE_SEPARATOR);
}
COOKIE_SPLITTER.split(value).forEach(cookieJoiner::add);
} else {
builder.add(name, convertHeaderValue(name, value));
}
}
if (cookieJoiner != null && cookieJoiner.length() != 0) {
builder.add(HttpHeaderNames.COOKIE, cookieJoiner.toString());
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: toArmeria
File: core/src/main/java/com/linecorp/armeria/internal/ArmeriaHttpUtil.java
Repository: line/armeria
The code follows secure coding practices.
|
[
"CWE-74"
] |
CVE-2019-16771
|
MEDIUM
| 5
|
line/armeria
|
toArmeria
|
core/src/main/java/com/linecorp/armeria/internal/ArmeriaHttpUtil.java
|
b597f7a865a527a84ee3d6937075cfbb4470ed20
| 0
|
Analyze the following code function for security vulnerabilities
|
@NonNull
public Account[] getAccounts(int userId, String opPackageName) {
int callingUid = Binder.getCallingUid();
mAppOpsManager.checkPackage(callingUid, opPackageName);
List<String> visibleAccountTypes = getTypesVisibleToCaller(callingUid, userId,
opPackageName);
if (visibleAccountTypes.isEmpty()) {
return EMPTY_ACCOUNT_ARRAY;
}
final long identityToken = clearCallingIdentity();
try {
UserAccounts accounts = getUserAccounts(userId);
return getAccountsInternal(
accounts,
callingUid,
opPackageName,
visibleAccountTypes,
false /* includeUserManagedNotVisible */);
} finally {
restoreCallingIdentity(identityToken);
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: getAccounts
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
|
getAccounts
|
services/core/java/com/android/server/accounts/AccountManagerService.java
|
f810d81839af38ee121c446105ca67cb12992fc6
| 0
|
Analyze the following code function for security vulnerabilities
|
public WorkBundle inboundSpaceTake(final HttpServletRequest req) throws NamespaceException {
final String spaceName = RequestUtil.getParameter(req, SPACE_NAME);
// Look up the place reference
final WorkSpace space = lookupSpace(spaceName);
if (space == null) {
throw new IllegalArgumentException("No WorkSpace found using name " + spaceName);
}
String placeName = RequestUtil.getParameter(req, CLIENT_NAME);
if (placeName == null) {
placeName = req.getRemoteHost();
}
return space.take(placeName);
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: inboundSpaceTake
File: src/main/java/emissary/server/mvc/adapters/WorkSpaceAdapter.java
Repository: NationalSecurityAgency/emissary
The code follows secure coding practices.
|
[
"CWE-502"
] |
CVE-2021-32634
|
MEDIUM
| 6.5
|
NationalSecurityAgency/emissary
|
inboundSpaceTake
|
src/main/java/emissary/server/mvc/adapters/WorkSpaceAdapter.java
|
40260b1ec1f76cc92361702cc14fa1e4388e19d7
| 0
|
Analyze the following code function for security vulnerabilities
|
private void parseRegion(final Element e, final Element prevRegion, final XmlSerializer serializer) throws Exception
{
boolean inRightOfPrevious = false;
try
{
if (prevRegion != null)
{
final int prevTop = Integer.parseInt(prevRegion.getAttribute("top"));
final int prevButton = prevTop + Integer.parseInt(prevRegion.getAttribute("height"));
final int thisTop = Integer.parseInt(e.getAttribute("top"));
final int thisButton = thisTop + Integer.parseInt(e.getAttribute("height"));
final int thisCenter = (thisTop + thisButton) / 2;
if (thisCenter > prevTop && thisCenter < prevButton)
{
inRightOfPrevious = true;
}
}
}
catch (Exception ex)
{
// nothing to do
}
final List<Element> elements = XmlUtils.getElements(e);
final String targetLanguage = getTargetLanguage(elements, "text");
for (Element en : elements)
{
if ("text".equals(en.getTagName()))
{
if (targetLanguage == null || XmlUtils.ensureAttribute(en, "lang", targetLanguage))
{
parseTextFragment(en, inRightOfPrevious, serializer);
}
}
else if ("math".equals(en.getTagName()))
{
parseMathExpression(en, inRightOfPrevious, serializer);
}
else if ("plot".equals(en.getTagName()))
{
parsePlot(en, inRightOfPrevious, serializer);
}
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: parseRegion
File: app/src/main/java/com/mkulesh/micromath/io/ImportFromSMathStudio.java
Repository: mkulesh/microMathematics
The code follows secure coding practices.
|
[
"CWE-611"
] |
CVE-2018-1000821
|
HIGH
| 7.5
|
mkulesh/microMathematics
|
parseRegion
|
app/src/main/java/com/mkulesh/micromath/io/ImportFromSMathStudio.java
|
5c05ac8de16c569ff0a1816f20be235090d3dd9d
| 0
|
Analyze the following code function for security vulnerabilities
|
public void setBodyRowHeight(double rowHeight) {
getState().bodyRowHeight = rowHeight;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: setBodyRowHeight
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
|
setBodyRowHeight
|
server/src/main/java/com/vaadin/ui/Grid.java
|
c40bed109c3723b38694ed160ea647fef5b28593
| 0
|
Analyze the following code function for security vulnerabilities
|
final boolean remove(CharSequence name) {
requireNonNull(name, "name");
final int h = AsciiString.hashCode(name);
return remove0(h, index(h), name) != null;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: remove
File: core/src/main/java/com/linecorp/armeria/common/HttpHeadersBase.java
Repository: line/armeria
The code follows secure coding practices.
|
[
"CWE-74"
] |
CVE-2019-16771
|
MEDIUM
| 5
|
line/armeria
|
remove
|
core/src/main/java/com/linecorp/armeria/common/HttpHeadersBase.java
|
b597f7a865a527a84ee3d6937075cfbb4470ed20
| 0
|
Analyze the following code function for security vulnerabilities
|
@Override
public void acceptJsonFormatVisitor(JsonFormatVisitorWrapper visitor, JavaType typeHint)
throws JsonMappingException
{
//deposit your output format
if (visitor == null) {
return;
}
JsonObjectFormatVisitor objectVisitor = visitor.expectObjectFormat(typeHint);
if (objectVisitor == null) {
return;
}
final SerializerProvider provider = visitor.getProvider();
if (_propertyFilterId != null) {
PropertyFilter filter = findPropertyFilter(visitor.getProvider(),
_propertyFilterId, null);
for (int i = 0, end = _props.length; i < end; ++i) {
filter.depositSchemaProperty(_props[i], objectVisitor, provider);
}
} else {
Class<?> view = ((_filteredProps == null) || (provider == null))
? null : provider.getActiveView();
final BeanPropertyWriter[] props;
if (view != null) {
props = _filteredProps;
} else {
props = _props;
}
for (int i = 0, end = props.length; i < end; ++i) {
BeanPropertyWriter prop = props[i];
if (prop != null) { // may be filtered out unconditionally
prop.depositSchemaProperty(objectVisitor, provider);
}
}
}
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: acceptJsonFormatVisitor
File: src/main/java/com/fasterxml/jackson/databind/ser/std/BeanSerializerBase.java
Repository: FasterXML/jackson-databind
The code follows secure coding practices.
|
[
"CWE-502"
] |
CVE-2019-16942
|
HIGH
| 7.5
|
FasterXML/jackson-databind
|
acceptJsonFormatVisitor
|
src/main/java/com/fasterxml/jackson/databind/ser/std/BeanSerializerBase.java
|
54aa38d87dcffa5ccc23e64922e9536c82c1b9c8
| 0
|
Analyze the following code function for security vulnerabilities
|
@NonNull
public BigPictureStyle bigLargeIcon(@Nullable Icon icon) {
mBigLargeIconSet = true;
mBigLargeIcon = icon;
return this;
}
|
No Vulnerability Detected:
This code is secure and does not contain known vulnerabilities.
Function: bigLargeIcon
File: core/java/android/app/Notification.java
Repository: android
The code follows secure coding practices.
|
[
"CWE-862"
] |
CVE-2023-21288
|
MEDIUM
| 5.5
|
android
|
bigLargeIcon
|
core/java/android/app/Notification.java
|
726247f4f53e8cc0746175265652fa415a123c0c
| 0
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.