Skip to main content

Symmetric denial of service - FTP

Description

The server crash is generated with multiple requests with the functionality Configuration and Programming Reverse Homologation that takes time to process the information when making the request with the selected SFTP (SSH) protocol, causing a 504 error in the application.

Impact

Cause a denial of service.

Recommendation

Define a time-out when a query or a search is taking too long to process the information.

Threat

Authenticated attacker in the application.

Expected Remediation Time

⌚ 60 minutes.

Score

Default score using CVSS 3.1. It may change depending on the context of the vulnerability.

Base

  • Attack vector: N
  • Attack complexity: L
  • Privileges required: L
  • User interaction: N
  • Scope: U
  • Confidentiality: N
  • Integrity: N
  • Availability: H

Temporal

  • Exploit code madurity: X
  • Remediation level: X
  • Report confidence: X

Result

  • Vector string: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H/E:X/RL:X/RC:X
  • Score:
    • Base: 6.5
    • Temporal: 6.5
  • Severity:
    • Base: Medium
    • Temporal: Medium

Code Examples

Compliant code

Potentially large queries include a timeout limit to avoid overloading

void initStatement(Connection conn, Statement stmt) throws SQLException {
int queryTimeout = 3600;
try {
stmt.setQueryTimeout(queryTimeout);
rs = stmt.executeQuery(validateQuery);
return true;
} catch {
//Throw exception when query takes two long
}
}

Non compliant code

The application performs potentially large queries without setting a timeout limit

void initStatement(Connection conn, Statement stmt) throws SQLException {
int queryTimeout = 3600;
rs = stmt.executeQuery(validateQuery);
//Handle query without limiting its time to execute
}

Requirements

free trial

Search for vulnerabilities in your apps for free with our automated security testing! Start your 21-day free trial and discover the benefits of our Continuous Hacking Machine Plan. If you prefer a full service that includes the expertise of our ethical hackers, don't hesitate to contact us for our Continuous Hacking Squad Plan.