Skip to content
RCE Write-up Advanced

VMware VeloCloud Orchestrator

RealmodeLabs Follow

Published on medium.com

This is the last part of our SD-PWN series where we present severe vulnerabilities in four of the leading SD-WAN vendors. This time focusing on VMware’s SD-WAN platform.

Ariel Tempelhof, on medium.com

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Written with AI from the full original report and checked against it passage by passage; anything it could not back up was removed or toned down. The original is the record. 9 min read.

This is the last part of our SD-PWN series, in which we present severe vulnerabilities in four of the leading SD-WAN vendors. This time we focus on VMware's SD-WAN platform. If you have not read the previous posts, they cover Silver Peak Unity Orchestrator, Citrix SD-WAN Center and Cisco Viptela vManage.

From the original on medium.com

If you use VMware VeloCloud Orchestrator, update immediately. As the following demonstrates, the issues below lead to unauthenticated remote code execution. As with the other products in this series, the ramifications can be used to disrupt the entire international network of a company.

Context

VMware VeloCloud Orchestrator connects to the edge routers and centrally controls the network topology. This is why it is a crucial single point of failure from a security perspective.

From the original on medium.com

The VeloCloud infrastructure consists of nginx serving mainly as a reverse proxy for node.js servers.

Setup

One of the first steps in a security survey of a product is to map out the unauthenticated interfaces it exposes. The obvious ones are the login and password reset.

The general password reset concept is straightforward:

  1. Generate one of the two:
    • A random unique key that cannot be predicted
    • A signed token
  2. Send it using a predefined side channel that is assumed to be in the sole possession of the user (email or SMS)
  3. Prompt the user to enter the random key

In step 1, VeloCloud made two grave mistakes.

Instead of generating random bytes for the reset key, VeloCloud probably looked at the users table in their database and said to themselves: we need some random bytes, here are some seemingly random bytes, the user's hashed password, why not use this?

Furthermore, they did implement an encrypted, signed token, but also added an option to use an unsigned cleartext one using the {CLEAR} prefix.

These two issues constitute what is known as a Pass The Hash attack.

Finding it

How do we know the hashed password? Normally we would try to find other vulnerabilities for database data extraction, namely SQL injections. But this is where it becomes interesting: VeloCloud has used a practice we have seen less of in the past years. They added predefined backdoor users.

To be fair, the backdoor users are disabled by default, and probably no one except VeloCloud knows their passwords, only their hashed values. However, the PTH attack allows us to use the hashed password during the password reset procedure, which also reenables the user.

These three issues lead to the first CVE.

Exploitation

Step 1: Authentication bypass using PTH and default accounts (CVE-2020-4001)

Using the previously described procedure we were able to reset the [redacted] account, which possesses the highest admin rights in the system, and after doing so it was no longer disabled. The attacker's prior knowledge is:

  • [redacted]'s hashed password
  • A parameter called logicalId

Both are predefined and can be obtained from the installation files. These values do not change between instances of the system.

This issue leverages all the rest and allows them to be run by an unauthenticated party.

Step 2: Modulus parameter SQL injection (CVE-2020-3984)

This is a standard SQL injection vulnerability in which user-controlled data is concatenated to an SQL query without escaping any characters. One of the places this is happening is the softwareUpdate/getSoftwareUpdates method using the modulus parameter. This SQLi enables us to extract any data from the database (it is non-blind).

Step 3: Rest Meta directory traversal and unauthenticated file inclusion (CVE-2020-4000)

The portal/rest/meta handler uses req.originalUrl to get the request method. The originalUrl is then used to require a file. Putting a .. sign in the path itself will be resolved by the webserver and omitted, but originalUrl includes the full GET query string, including the GET parameters. Using URLs with .. after the ? sign results in directory traversal.

Text
/portal/rest/meta/none?test/%2E%2E/%2E%2E/%2E%2E/%2E%2E/%2E%2E/%2E%2E/somefile.js

The path segment before the query string is none, and the traversal lives in the query string, which originalUrl includes. This primitive enables us to execute almost any JavaScript file on the local disk.

Although this issue is exposed to an unauthenticated attacker, we have not found an unauthenticated way to upload a file so that it can be included. We tried to think about ways to deliver JS code from the network instead of the disk (for example using /proc/self/fd/*), but that did not work, and we had already found the other vulnerabilities, which were enough. If you have any voodoo Linux tricks that can help require controlled content without dropping a file to disk, we would love to hear from you.

Step 4: The RCE chain

We have not found any straightforward shell injections. Our main approach was to utilise the file inclusion vulnerability by uploading a JavaScript file with controlled content. Still, all places involving a file upload had restrictions on the content. Then we looked at the generic file upload module and noticed that uploaded files which did not pass the content verification are not being deleted.

The filename is randomly generated and not returned to the user. The only part that was aware of the filename was the logger module. Thankfully VeloCloud added the feature of setting the syslog server of the device. So this is our RCE chain:

  1. Reset [redacted]'s password (thus enabling it)
  2. Log in using the newly enabled account
  3. Set our own server as the system's syslog server
  4. Upload a JavaScript file
  5. Receive the random filename using an incoming syslog message
  6. Use the Rest Meta file inclusion to require the JavaScript file

This leads to our JavaScript code running in node.js. The POC script is published as RealmodeLabs/SD-PWN.

Root cause

Three design mistakes combine here.

First, the password reset key is derived from the user's stored password hash rather than from fresh random bytes. A value that is supposed to be secret is therefore derived from the user's stored hash.

Second, the reset token format accepts an unsigned cleartext variant selected with the {CLEAR} prefix, so the integrity protection that the signed token would provide can be bypassed.

Third, the product ships predefined accounts, including [redacted], disabled by default. Because the reset procedure accepts the hash and reenables the account, a disabled account is not a barrier.

The SQL injection in softwareUpdate/getSoftwareUpdates is a plain concatenation of the modulus parameter into a query with no escaping, so the database layer never sees the input as data.

The file inclusion comes from using req.originalUrl, which contains the raw query string, as the argument to require. The webserver resolves and omits .. in the path, but originalUrl includes the full query string, so traversal placed after the ? survives.

The upload module verifies content but leaves rejected files on disk, and the random filename is only exposed through the logger, which can be pointed at an attacker-controlled syslog server. Each of these is a small weakness; together they turn an unauthenticated file inclusion into code execution.

Impact

An unauthenticated attacker can reset and reenable the [redacted] account, which holds the highest admin rights in the system, and from there reach remote code execution on the orchestrator. Because the orchestrator centrally controls the network topology and connects to the edge routers, the ramifications, as with the other products in this series, can be used to disrupt the entire international network of a company.

The SQL injection alone allows extraction of any data from the database. The file inclusion alone allows execution of almost any JavaScript file on the local disk, but without a way to place controlled content on disk it is not by itself code execution; the upload and syslog steps supply that content and its name.

Fix

Update VMware VeloCloud Orchestrator immediately. The report does not describe the vendor's patches; the fixes implied by the root causes are to generate reset keys from a cryptographically random source instead of the password hash, to refuse unsigned cleartext reset tokens, , to parameterise the modulus query, to resolve the require target from a validated method name rather than req.originalUrl, and to delete uploads that fail content verification.

Variants to test

  1. Reset key derived from stored secrets. Request a password reset for an account and inspect the key or token. A positive result is a key that is stable across requests, matches a hash format, or can be recomputed from values found in installation files.
  2. Unsigned token prefixes. Try submitting reset tokens with prefixes such as {CLEAR} alongside a known hash. A positive result is acceptance of a token whose signature was never verified.
  3. Predefined accounts. Enumerate default accounts and installation-file parameters such as logicalId. A positive result is a disabled account that becomes active after a reset performed with predefined values.
  4. Query-string traversal into require. Send requests of the form /portal/rest/meta/none?test/%2E%2E/%2E%2E/... against other node.js handlers that build paths from req.originalUrl. A positive result is a response that reflects the contents or behaviour of a file outside the intended directory.
  5. Orphaned uploads. Upload files that fail content verification, then look for them on disk. A positive result is a rejected upload that remains present and reachable by path.
  6. Filename leakage through logging. Configure a syslog destination you control and trigger uploads. A positive result is a log message containing the randomly generated filename.
  7. SQL injection in update methods. Test parameters such as modulus in softwareUpdate/getSoftwareUpdates with quote and boolean variations. A positive result is a non-blind difference in the response that confirms concatenation into the query.

Closing remarks

This concludes our SD-PWN series. If you look at the SD-WAN products that are out there, there is something they have in common that we thought should get some notice. Many of them are products that originated in startups and were later acquired by large companies. Silver Peak was acquired by HPE, Viptela by Cisco and VeloCloud by VMware. Talari was acquired by Oracle, but it looks like Citrix shares some of their codebase.

The thing is that startup companies usually put less emphasis on securing their products. They need to build a system from scratch, they have tight development schedules, code is often left unreviewed and sometimes shortcuts are made. Some of the issues were trivial, some were more complicated, but they were all bugs that could have been found and fixed by a standard security review. This is why a security-focused pair of eyes needs to inspect crucial parts of the code.

If you are interested in auditing your products, or performing special security research, you can find us on Twitter, LinkedIn or contact us at [redacted].

This is not a goodbye. Our next post will focus on an everyday gadget many of us use, and how we found some interesting, yet disturbing, issues with it.

Written with AI from the full original report and checked against it passage by passage; anything it could not back up was removed or toned down. The original is the record. 23 min read.

What happened, in plain words

This is the last part of our SD-PWN series, in which we present severe vulnerabilities in four of the leading SD-WAN vendors. This time we focus on VMware's SD-WAN platform. If you have not read the previous posts, they cover Silver Peak Unity Orchestrator, Citrix SD-WAN Center and Cisco Viptela vManage.

From the original on medium.com

If you use VMware VeloCloud Orchestrator, update immediately. As the following demonstrates, the issues below lead to unauthenticated remote code execution. As with the other products in this series, the ramifications can be used to disrupt the entire international network of a company.

Before going further, a few words for readers who have never done security work. A vulnerability is a mistake in software that lets someone make the software do something its maker did not intend. Remote code execution (RCE) means an attacker can make the machine run code of their choosing, from somewhere else on the network, without ever sitting at the keyboard. Unauthenticated means the attacker does not need a username or password to start. SD-WAN stands for software-defined wide area network: it is the set of products a company uses to connect its offices and data centres over the internet, and to decide which traffic goes where. If an attacker controls the thing that decides the routes, they control the company's network.

Context

VMware VeloCloud Orchestrator connects to the edge routers and centrally controls the network topology. This is why it is a crucial single point of failure from a security perspective.

From the original on medium.com

An edge router is the box at each office that connects that office to the outside world. The orchestrator is the central management console: it talks to all those routers and tells them how to route traffic. A single point of failure is one component whose failure (or compromise) breaks everything that depends on it. If the orchestrator is taken over, every router it manages can be told to do something else.

The VeloCloud infrastructure consists of nginx serving mainly as a reverse proxy for node.js servers.

Two terms here. nginx is a web server: software that answers requests coming in over HTTP (the protocol your browser uses). A reverse proxy is a web server that sits in front of other servers and forwards requests to them, like a receptionist who takes every visitor's name and sends them to the right office. node.js is a program that runs JavaScript outside the browser, on a server. So the picture is: a request arrives at nginx, nginx passes it to a node.js program, and that program does the real work.

Setup

One of the first steps in a security survey of a product is to map out the unauthenticated interfaces it exposes. The obvious ones are the login and password reset.

An interface here means a web address the product answers without asking who you are. The login page is obvious. The password reset page is the one where you type your email address and the site sends you a link or a code so you can choose a new password. It has to work without a password, which is exactly why it is interesting to an attacker.

The general password reset concept is straightforward:

  1. Generate one of the two:
    • A random unique key that cannot be predicted
    • A signed token
  2. Send it using a predefined side channel that is assumed to be in the sole possession of the user (email or SMS)
  3. Prompt the user to enter the random key

Step by step, in everyday terms:

  1. The site makes a secret. It can be a random key: a long string of characters produced by a random number generator, so that nobody can guess the next one. Or it can be a signed token: a piece of data plus a mathematical stamp (a signature) that lets the server check later that it produced the data itself and nobody altered it. A signature is like a wax seal on an envelope: anyone can carry the envelope, but only the sender can make the seal.
  2. The secret is delivered over a side channel, meaning a route other than the website itself: email or SMS. The assumption is that only the real user can read that email or receive that text.
  3. The user types the secret back into the site, proving they received it.

In step 1, VeloCloud made two grave mistakes.

Instead of generating random bytes for the reset key, VeloCloud probably looked at the users table in their database and said to themselves: we need some random bytes, here are some seemingly random bytes, the user's hashed password, why not use this?

A database is where a web application stores its data, in tables with rows and columns, much like a spreadsheet. The users table has one row per account. A password hash is what you get when you put a password through a one-way mathematical function: the same password always gives the same output, but you cannot turn the output back into the password. Sites store hashes rather than passwords so that a database leak does not hand over the real passwords. The mistake here is that the hash looks like random characters, so it was reused as if it were a random key. But a hash is not random: it is fixed for a given password, and it sits in the database and in installation files.

Furthermore, they did implement an encrypted, signed token, but also added an option to use an unsigned cleartext one using the {CLEAR} prefix.

Encrypted means scrambled so that only the holder of the right key can read it. Cleartext means not scrambled at all. A prefix is a short piece of text at the start of a value that tells the software how to treat the rest. So the reset token could be sent in a protected form, or in a form marked {CLEAR} that skips the protection entirely. The seal on the envelope could simply be left off.

These two issues constitute what is known as a Pass The Hash attack.

Pass The Hash (PTH) is an attack where the attacker does not need the password itself, only its hash. Normally a hash is useless to an attacker because it cannot be turned back into a password. But if a system accepts the hash as proof of identity, the hash becomes as good as the password. The comparison: a bouncer who checks a membership card by its number rather than by the photo will let in anyone who knows the number.

Finding it

How do we know the hashed password? Normally we would try to find other vulnerabilities for database data extraction, namely SQL injections. But this is where it becomes interesting: VeloCloud has used a practice we have seen less of in the past years. They added predefined backdoor users.

An SQL injection is a vulnerability where an attacker's input is treated as part of a database command instead of as plain data. SQL is the language used to talk to databases. If a site builds a query by gluing your input into it, you can write input that changes the query. We will see a concrete example in step 2.

A backdoor user is an account the vendor built into the product, usually for support access, that the customer did not create and may not know about. Predefined means the account exists in every installation, with the same values, before anyone configures anything.

To be fair, the backdoor users are disabled by default, and probably no one except VeloCloud knows their passwords, only their hashed values. However, the PTH attack allows us to use the hashed password during the password reset procedure, which also reenables the user.

Disabled by default means the account exists but cannot log in until someone turns it on. That sounds safe. The problem is that the reset procedure accepts the hash and, as a side effect, turns the account back on. So the disabled state is not a barrier at all.

These three issues lead to the first CVE.

A CVE is a public catalogue number for a known vulnerability, like a registration plate for a security bug. It lets vendors, customers and tools refer to the same issue unambiguously.

Exploitation

Step 1: Authentication bypass using PTH and default accounts (CVE-2020-4001)

Authentication is the process of proving who you are, usually with a username and password. An authentication bypass is any trick that gets you past that check without knowing the credentials. Exploitation means actually carrying out the attack, not just suspecting it is possible.

Using the previously described procedure we were able to reset the [redacted] account, which possesses the highest admin rights in the system, and after doing so it was no longer disabled. The attacker's prior knowledge is:

  • [redacted]'s hashed password
  • A parameter called logicalId

Both are predefined and can be obtained from the installation files. These values do not change between instances of the system.

A parameter is a named value sent along with a request, for example ?logicalId=123. The name is the label, the value is what follows the equals sign. Installation files are the files shipped with the product that you copy onto the server when you set it up. If a secret lives in those files, then everyone who has ever installed the product has the same secret. That is why the report stresses that the values do not change between instances: one leaked value works against every customer.

This issue leverages all the rest and allows them to be run by an unauthenticated party.

Leverages here means uses as a starting point. The account reset is the door opener: once you are the top administrator, every other feature described below can be reached with normal, logged-in requests.

Step 2: Modulus parameter SQL injection (CVE-2020-3984)

This is a standard SQL injection vulnerability in which user-controlled data is concatenated to an SQL query without escaping any characters. One of the places this is happening is the softwareUpdate/getSoftwareUpdates method using the modulus parameter. This SQLi enables us to extract any data from the database (it is non-blind).

Concatenated means joined end to end, like gluing words into a sentence. Escaping means marking special characters in user input so the database treats them as text rather than as commands. If a site does neither, the input becomes part of the command.

A method in this context is a named operation the server offers, reachable at a web address. softwareUpdate/getSoftwareUpdates is the name of one such operation, and modulus is one of the parameters it accepts. Non-blind SQL injection means the attacker can see the results of their injected query in the response. Blind SQL injection means the attacker only gets yes/no differences and has to ask many questions to learn anything. Non-blind is much easier for an attacker.

Why this step matters: the report's earlier reasoning said that normally you would need a database leak to learn a password hash. Here the hash was already known from installation files, so the SQL injection was not needed for step 1. It is still a serious bug on its own, because it lets an attacker read any data in the database.

Step 3: Rest Meta directory traversal and unauthenticated file inclusion (CVE-2020-4000)

The portal/rest/meta handler uses req.originalUrl to get the request method. The originalUrl is then used to require a file. Putting a .. sign in the path itself will be resolved by the webserver and omitted, but originalUrl includes the full GET query string, including the GET parameters. Using URLs with .. after the ? sign results in directory traversal.

Several new words. A handler is the piece of code that runs when a particular web address is requested. req.originalUrl is a property in node.js that holds the exact address the browser asked for, including everything after the question mark. A GET request is the ordinary kind of request your browser makes when you open a page; its query string is the part after the ?, made of parameters such as ?name=value. require is a node.js function that loads and runs a JavaScript file from disk. Directory traversal (also called path traversal) is an attack where .. is used to climb out of the intended folder: .. means "the folder above this one", so enough of them reach the top of the disk.

Text
/portal/rest/meta/none?test/%2E%2E/%2E%2E/%2E%2E/%2E%2E/%2E%2E/%2E%2E/somefile.js

Line by line:

  • /portal/rest/meta/none is the path. none is not a valid method name, which is the point: the code still runs and still reads the address.
  • ? starts the query string. Everything after it is parameters.
  • test/ is the start of a parameter value.
  • %2E%2E is the URL-encoded form of ... URL encoding replaces characters that are awkward in a web address with a percent sign and a code, so %2E is a dot. Encoding is used here because the webserver resolves and omits plain .. in the path.
  • Six repetitions of %2E%2E climb six folders up.
  • /somefile.js is the file to load once the climb is done.

The path segment before the query string is none, and the traversal lives in the query string, which originalUrl includes. This primitive enables us to execute almost any JavaScript file on the local disk.

Normalise means tidy up: collapse .. and . so the address points where it really points. The webserver does that for the path but not for the query string, so the encoded dots survive into the value node.js uses. A primitive in security writing is a small building block of an attack: on its own it may not be enough, but it can be combined with other pieces.

Although this issue is exposed to an unauthenticated attacker, we have not found an unauthenticated way to upload a file so that it can be included. We tried to think about ways to deliver JS code from the network instead of the disk (for example using /proc/self/fd/*), but that did not work, and we had already found the other vulnerabilities, which were enough. If you have any voodoo Linux tricks that can help require controlled content without dropping a file to disk, we would love to hear from you.

Upload means sending a file from your computer to the server. The problem: the file inclusion can run any JavaScript file already on the disk, but the attacker needs a file on the disk whose contents they control. /proc/self/fd/* is a special area on Linux that represents open files; the idea was to feed code through it instead of writing a file, and it did not work. So this step alone is a serious bug but not yet code execution.

Step 4: The RCE chain

A chain is several small weaknesses used in sequence, where each one makes the next possible. None of them may be dramatic alone; together they reach code execution.

We have not found any straightforward shell injections. Our main approach was to utilise the file inclusion vulnerability by uploading a JavaScript file with controlled content. Still, all places involving a file upload had restrictions on the content. Then we looked at the generic file upload module and noticed that uploaded files which did not pass the content verification are not being deleted.

A shell injection is a vulnerability where input reaches the operating system's command line, letting an attacker run commands directly. The team looked for that first and did not find it. Content verification means the upload feature inspects the file and rejects it if it does not look like an allowed type. The flaw: rejection stops the file being used, but the file is left on disk anyway. Compare a nightclub that turns you away at the door but leaves your bag in the cloakroom.

The filename is randomly generated and not returned to the user. The only part that was aware of the filename was the logger module. Thankfully VeloCloud added the feature of setting the syslog server of the device. So this is our RCE chain:

A logger is the part of a program that writes event messages. Syslog is a standard format for such messages, and a syslog server is a machine that collects them over the network. The product lets an administrator choose which syslog server to send to. That is a normal feature for monitoring, and here it becomes the way to learn the random filename: point the logger at your own machine and read the message.

  1. Reset [redacted]'s password (thus enabling it)
  2. Log in using the newly enabled account
  3. Set our own server as the system's syslog server
  4. Upload a JavaScript file
  5. Receive the random filename using an incoming syslog message
  6. Use the Rest Meta file inclusion to require the JavaScript file

Why each step:

  1. The reset with the known hash turns the top administrator account back on and gives the attacker control of it.
  2. With that account, the attacker is now a legitimate logged-in administrator, so every feature below is available.
  3. The syslog setting is changed so that log messages, including filenames, arrive at a machine the attacker controls.
  4. The upload places the attacker's JavaScript on the server's disk, even though verification rejects it.
  5. The log message reveals the random name the server gave the file, which the upload response did not show.
  6. The traversal bug loads that file with require, and node.js runs it.

This leads to our JavaScript code running in node.js. The POC script is published as RealmodeLabs/SD-PWN.

A POC (proof of concept) is a small program that demonstrates the attack works, so others can verify it.

Root cause

Three design mistakes combine here.

First, the password reset key is derived from the user's stored password hash rather than from fresh random bytes. A value that is supposed to be secret and single-use is therefore a value that is fixed per installation and recoverable from the installation files.

Second, the reset token format accepts an unsigned cleartext variant selected with the {CLEAR} prefix, so the integrity protection that the signed token would provide can be bypassed.

Integrity protection means being able to tell that data has not been altered. A signature gives that; a cleartext token does not.

Third, the product ships predefined accounts, including [redacted], disabled by default. Because the reset procedure accepts the hash and reenables the account, a disabled account is not a barrier.

The SQL injection in softwareUpdate/getSoftwareUpdates is a plain concatenation of the modulus parameter into a query with no escaping, so the database layer never sees the input as data.

The file inclusion comes from using req.originalUrl, which contains the raw query string, as the argument to require. The webserver resolves .. in the path, but originalUrl includes the full query string, so traversal after the ? survives.

The upload module verifies content but leaves rejected files on disk, and the random filename is only exposed through the logger, which can be pointed at an attacker-controlled syslog server. Each of these is a small weakness; together they turn an unauthenticated file inclusion into code execution.

Impact

An unauthenticated attacker can reset and reenable the [redacted] account, which holds the highest admin rights in the system, and from there reach remote code execution on the orchestrator. Because the orchestrator centrally controls the network topology and connects to the edge routers, the ramifications, as with the other products in this series, can be used to disrupt the entire international network of a company.

The SQL injection alone allows extraction of any data from the database. The file inclusion alone allows execution of almost any JavaScript file on the local disk, but without a way to place controlled content on disk it is not by itself code execution; the upload and syslog steps supply that content and its name.

Fix

Update VMware VeloCloud Orchestrator immediately. The report does not describe the vendor's patches; the fixes implied by the root causes are to generate reset keys from a cryptographically random source instead of the password hash, to refuse unsigned cleartext reset tokens, , to parameterise the modulus query, to resolve the require target from a validated method name rather than req.originalUrl, and to delete uploads that fail content verification.

Cryptographically random means random in a way an attacker cannot predict even with a lot of computing power. Parameterise a query means send the input separately from the command, so the database always treats it as data and never as code.

Variants to test

These are checks a defender or researcher can run on similar products. Each one names what a positive result looks like.

  1. Reset key derived from stored secrets. Request a password reset for an account and inspect the key or token. A positive result is a key that is stable across requests or matches a hash format.
  2. Unsigned token prefixes. Try submitting reset tokens with prefixes such as {CLEAR} alongside a known hash. A positive result is acceptance of a token whose signature was never verified.
  3. Predefined accounts. Enumerate default accounts and installation-file parameters such as logicalId. A positive result is a disabled account that becomes active after a reset performed with predefined values.
  4. Query-string traversal into require. Send requests of the form /portal/rest/meta/none?test/%2E%2E/%2E%2E/... against other node.js handlers that build paths from req.originalUrl. A positive result is a response that reflects the contents or behaviour of a file outside the intended directory.
  5. Orphaned uploads. Upload files that fail content verification, then look for them on disk. A positive result is a rejected upload that remains present and reachable by path.
  6. Filename leakage through logging. Configure a syslog destination you control and trigger uploads. A positive result is a log message containing the randomly generated filename.
  7. SQL injection in update methods. Test parameters such as modulus in softwareUpdate/getSoftwareUpdates with quote and boolean variations. A positive result is a non-blind difference in the response that confirms concatenation into the query.

Enumerate means list out systematically. Boolean variations means inputs that try to make a condition true or false, to see whether the response changes.

Closing remarks

This concludes our SD-PWN series. If you look at the SD-WAN products that are out there, there is something they have in common that we thought should get some notice. Many of them are products that originated in startups and were later acquired by large companies. Silver Peak was acquired by HPE, Viptela by Cisco and VeloCloud by VMware. Talari was acquired by Oracle, but it looks like Citrix shares some of their codebase.

A startup is a young company building a product quickly, often with a small team. Acquired means bought by a larger company. A codebase is the whole body of source code behind a product.

The thing is that startup companies usually put less emphasis on securing their products. They need to build a system from scratch, they have tight development schedules, code is often left unreviewed and sometimes shortcuts are made. Some of the issues were trivial, some were more complicated, but they were all bugs that could have been found and fixed by a standard security review. This is why a security-focused pair of eyes needs to inspect crucial parts of the code.

A security review is a deliberate examination of code or a system, looking for mistakes an attacker could use, before an attacker finds them.

If you are interested in auditing your products, or performing special security research, you can find us on Twitter, LinkedIn or contact us at [redacted].

This is not a goodbye. Our next post will focus on an everyday gadget many of us use, and how we found some interesting, yet disturbing, issues with it.

Glossary

  • Authentication: proving who you are, usually with a username and password.
  • Authentication bypass: getting past the login check without valid credentials.
  • Backdoor user: an account built into a product by its vendor, not created by the customer.
  • Blind SQL injection: SQL injection where the attacker only sees yes/no differences, not the query results.
  • Boolean variations: test inputs that try to make a condition true or false, to see if the response changes.
  • Chain: several weaknesses used in sequence, each enabling the next.
  • Cleartext: data that is not encrypted or otherwise protected.
  • Codebase: the whole body of source code behind a product.
  • Concatenation: joining pieces of text end to end.
  • Content verification: checking an uploaded file and rejecting it if it does not look like an allowed type.
  • Cryptographically random: random in a way an attacker cannot predict.
  • CVE: a public catalogue number for a known vulnerability.
  • Database: where a web application stores its data, in tables of rows and columns.
  • Directory traversal: using .. to climb out of the intended folder and reach other files.
  • Disabled by default: an account or feature that exists but is switched off until someone turns it on.
  • Edge router: the device at an office that connects it to the outside network.
  • Encrypted: scrambled so only the holder of the right key can read it.
  • Enumerate: list out systematically.
  • Escaping: marking special characters in input so they are treated as text, not commands.
  • Exploitation: actually carrying out an attack.
  • GET request: the ordinary request a browser makes when opening a page; its parameters sit after the ?.
  • Handler: the code that runs when a particular web address is requested.
  • Hash (password hash): the fixed-looking output of a one-way function applied to a password; it cannot be turned back into the password.
  • Installation files: the files shipped with a product and copied onto the server during setup.
  • Integrity protection: the ability to tell that data has not been altered.
  • Interface (unauthenticated): a web address the product answers without asking who you are.
  • Leverage: use one weakness as the starting point for the next.
  • Logger: the part of a program that writes event messages.
  • Method: a named operation a server offers, reachable at a web address.
  • nginx: a web server often used in front of other servers.
  • Node.js: a program that runs JavaScript on a server, outside the browser.
  • Non-blind SQL injection: SQL injection where the attacker can see the query results in the response.
  • Normalise: tidy up an address so .. and . point where they really point.
  • Orchestrator: the central management console that controls many network devices.
  • Parameter: a named value sent with a request, such as ?name=value.
  • Parameterise (a query): send input separately from the command so the database treats it only as data.
  • Pass The Hash (PTH): an attack that uses a password hash, rather than the password, as proof of identity.
  • Password reset: the feature that lets a user choose a new password after proving they control their email or phone.
  • POC (proof of concept): a small program demonstrating that an attack works.
  • Prefix: a short piece of text at the start of a value that tells software how to treat the rest.
  • Predefined: existing in every installation with the same values before anyone configures anything.
  • Primitive: a small building block of an attack, useful when combined with others.
  • Query string: the part of a web address after the ?, made of parameters.
  • Remote code execution (RCE): making a machine run code of the attacker's choosing from elsewhere on the network.
  • require: a node.js function that loads and runs a JavaScript file from disk.
  • Reverse proxy: a web server that forwards incoming requests to other servers behind it.
  • SD-WAN: software-defined wide area network, the products a company uses to connect and route traffic between its sites.
  • Security review: a deliberate examination of code or a system for mistakes an attacker could use.
  • Shell injection: a vulnerability where input reaches the operating system's command line.
  • Side channel: a delivery route other than the website itself, such as email or SMS.
  • Signature (signed token): a mathematical stamp that lets the server check it produced the data and nobody altered it.
  • Single point of failure: one component whose failure or compromise breaks everything that depends on it.
  • SQL: the language used to talk to databases.
  • SQL injection: a vulnerability where input is treated as part of a database command instead of as data.
  • Startup: a young company building a product quickly, often with a small team.
  • Syslog: a standard format for log messages sent over a network.
  • Syslog server: a machine that collects syslog messages.
  • Token: a piece of data issued by a server and presented back later to prove something, such as a reset request.
  • Unauthenticated: without needing a username or password.
  • Upload: sending a file from a computer to a server.
  • URL encoding: writing awkward characters in a web address as a percent sign plus a code, such as %2E for a dot.
  • Users table: the database table with one row per account.
  • Vulnerability: a mistake in software that lets someone make it behave in a way its maker did not intend.

More by RealmodeLabs

View all

3 more disclosed reports, best first.

More from VMware

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Remote code execution

The lesson behind this report.

Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.