ESB-2018.0332 - [Win] CODESYS Web Server: Execute arbitrary code/commands - Remote/unauthenticated 2018-02-02

Printable version
PGP/GPG verifiable version

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

===========================================================================
             AUSCERT External Security Bulletin Redistribution

                               ESB-2018.0332
                         Advisory (ICSA-18-032-02)
                              2 February 2018

===========================================================================

        AusCERT Security Bulletin Summary
        ---------------------------------

Product:           CODESYS Web Server
Publisher:         ICS-CERT
Operating System:  Windows
Impact/Access:     Execute Arbitrary Code/Commands -- Remote/Unauthenticated
                   Denial of Service               -- Remote/Unauthenticated
Resolution:        Patch/Upgrade
CVE Names:         CVE-2018-5440  

Original Bulletin: 
   https://ics-cert.us-cert.gov/advisories/ICSA-18-032-02

- --------------------------BEGIN INCLUDED TEXT--------------------

3S-Smart Software Solutions GmbH CODESYS Web Server

Legal Notice

All information products included in http://ics-cert.us-cert.gov are provided
"as is" for informational purposes only. The Department of Homeland Security
(DHS) does not provide any warranties of any kind regarding any information
contained within. DHS does not endorse any commercial product or service,
referenced in this product or otherwise. Further dissemination of this product
is governed by the Traffic Light Protocol (TLP) marking in the header. For more
information about TLP, see http://www.us-cert.gov/tlp/.


CVSS v3 9.8

ATTENTION: Remotely exploitable/low skill level to exploit.

Vendor: 3S-Smart Software Solutions GmbH

Equipment: CODESYS Web Server

Vulnerability: Stack-based Buffer Overflow


AFFECTED PRODUCTS

All Microsoft Windows (also WinCE) based CODESYS web servers running stand-alone
Version 2.3, or as part of the CODESYS runtime system running prior to Version
V1.1.9.19, are affected.


IMPACT

Successful exploitation of this vulnerability could cause the device the
attacker is accessing to crash, resulting in a buffer overflow condition that
may allow remote code execution.


MITIGATION

This vulnerability will be fixed by patch V.1.1.9.19 for the CODESYS V2.3 web
server for Windows. This will be part of the CODESYS setup V2.3.9.56. The
release of this security patch was made available on January 30, 2018.

Currently, 3S-Smart Software Solutions GmbH has not identified any workarounds
for this vulnerability.

In general, 3S-Smart Software Solutions GmbH recommends the following defensive
measures to reduce the risk of exploitation of this vulnerability:

    Use controllers and devices only in a protected environment to minimize
    network exposure and ensure they are not accessible from outside.

    Use firewalls to protect and separate the control system network from other
    networks.

    Use VPN (Virtual Private Networks) tunnels if remote access is required.

    Protect both development and control systems from unauthorized access (e.g.,
    by means of the operating system).

    Protect both development and control system by using up-to-date virus
    detecting solutions.

For additional information regarding the CODESYS products, or about the
described vulnerability, please contact the 3S-Smart Software Solutions support
team at this location:

https://www.codesys.com/support-training/codesys-support.html

For additional information find the CODESYS Security update at the following
location:

https://customers.codesys.com/fileadmin/data/customers/security/2018/Advisory2018-01_LCDS-282.pdf

For more information and general recommendations for protecting machines and
manufacturing facilities, see the CODESYS Security whitepaper available at this
location:

https://customers.codesys.com/fileadmin/data/customers/security/CODESYS-Security-Whitepaper.pdf

NCCIC recommends users take defensive measures to minimize the risk of
exploitation of these vulnerabilities. Specifically, users should:

    Minimize network exposure for all control system devices and/or systems, and
    ensure that they are not accessible from the Internet.

    Locate control system networks and remote devices behind firewalls, and
    isolate them from the business network.

    When remote access is required, use secure methods, such as Virtual Private
    Networks (VPNs), recognizing that VPNs may have vulnerabilities and should
    be updated to the most current version available. Also recognize that VPN is
    only as secure as the connected devices.

NCCIC reminds organizations to perform proper impact analysis and risk
assessment prior to deploying defensive measures.

NCCIC also provides a section for control systems security recommended practices
on the ICS-CERT web page. Several recommended practices are available for
reading and download, including Improving Industrial Control Systems
Cybersecurity with Defense-in-Depth Strategies.

Additional mitigation guidance and recommended practices are publicly available
in the NCCIC Technical Information Paper, ICS-TIP-12-146-01B--Targeted Cyber
Intrusion Detection and Mitigation Strategies, that is available for download
from the ICS-CERT web site.

Organizations observing any suspected malicious activity should follow their
established internal procedures and report their findings to NCCIC for tracking
and correlation against other incidents.

No known public exploits specifically target this vulnerability.


VULNERABILITY OVERVIEW

STACK-BASED BUFFER OVERFLOW CWE-121

A crafted request may cause a buffer overflow and could therefore execute
arbitrary code on the web server or lead to a denial-of-service condition due to
a crash in the web server.

CVE-2018-5440 has been assigned to this vulnerability. A CVSS v3 base score of
9.8 has been assigned; the CVSS vector string is
(AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H).


RESEARCHER

Zhu WenZhe of Istury IOT security lab reported this vulnerability to NCCIC.


BACKGROUND

Critical Infrastructure Sectors: Critical Manufacturing, Energy

Countries/Areas Deployed: Worldwide

Company Headquarters Location: Kempten, Germany

Contact Information

For any questions related to this report, please contact the NCCIC at:

Email: NCCICCUSTOMERSERVICE@hq.dhs.gov
Toll Free: 1-888-282-0870

For industrial control systems cybersecurity information:
http://ics-cert.us-cert.gov

or incident reporting:  https://ics-cert.us-cert.gov/Report-Incident?

The NCCIC continuously strives to improve its products and services. You can
help by choosing one of the links below to provide feedback about this product.

- --------------------------END INCLUDED TEXT--------------------

You have received this e-mail bulletin as a result of your organisation's
registration with AusCERT. The mailing list you are subscribed to is
maintained within your organisation, so if you do not wish to continue
receiving these bulletins you should contact your local IT manager. If
you do not know who that is, please send an email to auscert@auscert.org.au
and we will forward your request to the appropriate person.

NOTE: Third Party Rights
This security bulletin is provided as a service to AusCERT's members.  As
AusCERT did not write the document quoted above, AusCERT has had no control
over its content. The decision to follow or act on information or advice
contained in this security bulletin is the responsibility of each user or
organisation, and should be considered in accordance with your organisation's
site policies and procedures. AusCERT takes no responsibility for consequences
which may arise from following or acting on information or advice contained in
this security bulletin.

NOTE: This is only the original release of the security bulletin.  It may
not be updated when updates to the original are made.  If downloading at
a later date, it is recommended that the bulletin is retrieved directly
from the author's website to ensure that the information is still current.

Contact information for the authors of the original document is included
in the Security Bulletin above.  If you have any questions or need further
information, please contact them directly.

Previous advisories and external security bulletins can be retrieved from:

        https://www.auscert.org.au/bulletins/

===========================================================================
Australian Computer Emergency Response Team
The University of Queensland
Brisbane
Qld 4072

Internet Email: auscert@auscert.org.au
Facsimile:      (07) 3365 7031
Telephone:      (07) 3365 4417 (International: +61 7 3365 4417)
                AusCERT personnel answer during Queensland business hours
                which are GMT+10:00 (AEST).
                On call after hours for member emergencies only.
===========================================================================
-----BEGIN PGP SIGNATURE-----
Comment: http://www.auscert.org.au/render.html?it=1967

iQIVAwUBWnPKL4x+lLeg9Ub1AQh/JhAAjclUl77NQa+92lDyIzoS8imks4mBq+Z0
LE6ullLiqvKRI3fDunX3QZ1Gq14NSqq0YmO7On3zyE+b+4NO1/k7ShkfjSttZj1c
JLVLWduaFB+gPpvay1t6anPJKgXwvpDHxWs0E63GvaKda3hRgXlB10w0EXMvgTlr
k4fnmG4szsj1MgtqWKE+XzJzym5A6U6j29EDgmoS7iZ9hGPCDQzgmuNB0ZjPSalY
XATUt46PnEJ43bLp5KdQION4kScpPRhdyp7HSzX+4ta7ezs2jtV9KK9o8AkfrJWa
hAySq1xGM61J7UMi7o8IbdguaiTnr0SF/oyzdEFopaJcS3Gt+okjOqrN0muvNRuI
quM9AIcnHZa3h11wPDbHu4Wtmsu2EvcrHzCuF0U2JuGJKE0xL5AGKOqtv42ybrqc
uHEK1u+YlbLzKtA8tyf3GEai8wLMiC9ZbTNDyZJ8D44GppEx/5vli2Bp7ddG0awY
P2620oR7WFX8Dd8hWtlaksFsRqAXcYHoXfaQAWpTi9IoGLbbuLH5UxISX8e8nGFI
RdiOkN5gBR88oGdUQt7BigOFVZb5Dke8paVlafMZDJjlvPvcicOOwsHFuH3ASlhJ
4bugCggZHSYZvTB6wrckcRjWk1BoC/4VQdIozghbBFLgZEa19NgvxPhgJ12Omzdh
WIpY2psZOHo=
=6u3r
-----END PGP SIGNATURE-----

« Back to bulletins