# Portable Media

### **Understanding the Attack**

**Definition**&#x20;

A portable media attack involves distributing malicious files via removable media devices. The victim is deceived into executing the file, which then performs harmful actions on their system. In Lucy's context, success is measured by retrieving the executed data from the victim's computer.

***

### **Checklist**

* [x] [Register an Attack Domain](https://wiki.lucysecurity.com/application-reference/settings/common-system-settings/domains#register-a-domain-via-the-domain-registration-wizard)
* [x] [Add a Portable Media Attack to your Campaign](https://wiki.lucysecurity.com/application-reference/campaigns/campaign-settings/main-settings/attack-simulation)
* [x] [Ensure the success action is File Data Received](https://wiki.lucysecurity.com/application-reference/campaigns/campaign-settings/main-settings/attack-simulation#success-action)
* [x] [Ensure the File is excluded from Anti-Virus scanning in your infrastructure](https://wiki.lucysecurity.com/guides/whitelisting-a-lucy-server/file-attack-whitelisting)

***

### **Real-world Examples**

* **USB Stick in Public Places:** A USB stick labeled "Confidential - Company Financials" is left in a company parking lot. An employee finds it and inserts it into their computer out of curiosity, executing the malicious file.
* **CD with Company Branding:** A CD labeled "Employee Benefits Overview" is mailed to employees. When they insert the CD and open the file, it executes malicious code.
* **Infected SD Cards:** An SD card labeled "Project Files" is distributed at a conference. Attendees insert the card into their computers to access the files, unknowingly executing the malicious software.

***

### Configuration

**Create a New Campaign:**

* Navigate to the Campaigns Dashboard and select the "New Campaign" button. Choose the "Attack Simulation" campaign type.

<figure><img src="https://3536856424-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FVYPsDfg76rUuy4DWfSsJ%2Fuploads%2FuELK39tC1eKRq5sCWAOX%2Fimage.png?alt=media&#x26;token=9a7fc001-e60c-4205-aabd-8e7607c66b96" alt="" width="563"><figcaption></figcaption></figure>

#### **Choose Attack Type:**

* Select -> **Skip Wizard and enable expert setup**

<figure><img src="https://3536856424-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FVYPsDfg76rUuy4DWfSsJ%2Fuploads%2FYacAPKN3OQbwlXv2dHED%2Fimage.png?alt=media&#x26;token=f7f2c667-79e1-4c2d-9076-e6e266849d71" alt="" width="563"><figcaption></figcaption></figure>

#### Give the scenario a name and client:

<figure><img src="https://3536856424-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FVYPsDfg76rUuy4DWfSsJ%2Fuploads%2FzN8Lum3tKyycOd6Mz7OZ%2Fimage.png?alt=media&#x26;token=f975122d-be6d-4110-8ccc-0a3584c16cc9" alt=""><figcaption></figcaption></figure>

#### Navigate to Attack Settings and select New Scenario:

<figure><img src="https://3536856424-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FVYPsDfg76rUuy4DWfSsJ%2Fuploads%2FsVdj8uYjXmHHiGDYxrXU%2Fimage.png?alt=media&#x26;token=2a381aed-4db9-4d2b-9ef6-64a4b4fde197" alt="" width="563"><figcaption></figcaption></figure>

**Select the Portable Media Attack Template:**

* Select the "Portable Media Attack" scenario and click "Use template".&#x20;

{% hint style="info" %}
If it's not available, download it by first navigating to **Templates ->** [**Download Templates**](https://wiki.lucysecurity.com/application-reference/templates/download-templates) and searching for "**Portable Media Attack**".
{% endhint %}

<figure><img src="https://3536856424-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FVYPsDfg76rUuy4DWfSsJ%2Fuploads%2F5Z1JunOYimA1odiRMiBA%2Fimage.png?alt=media&#x26;token=73884cc9-b8ea-4561-831b-c5242b8346f1" alt="" width="563"><figcaption></figcaption></figure>

**Give the Scenario a Name and Pick a Domain:**

* Specify the domain or IP used upon execution. The malware simulation will send data back to this host.
* Specify what constitutes a successful attack, by default this will be set to "Data Submit" and click "Save"

<figure><img src="https://3536856424-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FVYPsDfg76rUuy4DWfSsJ%2Fuploads%2Fj4wwUre6CC2bBfoScg0l%2Fimage.png?alt=media&#x26;token=b962559a-16fa-42ee-be5b-d321dfdf39fb" alt=""><figcaption></figcaption></figure>

**Add your Portable Media recipient group:**

{% hint style="info" %}
Portable Media recipients are automatically generated by the system to track each file created for a portable media device and do not use company email addresses.
{% endhint %}

* Navigate to **Configuration -> Recipients -> "Add Group"**
* Add your Portable Media recipient group:

<figure><img src="https://3536856424-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FVYPsDfg76rUuy4DWfSsJ%2Fuploads%2F8TmsrBbvPRhhBflspEUs%2Fimage.png?alt=media&#x26;token=059bd8e5-f12b-481c-a12b-c8552a035a10" alt=""><figcaption></figcaption></figure>

<figure><img src="https://3536856424-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FVYPsDfg76rUuy4DWfSsJ%2Fuploads%2FwTgpVTuCwD7OShq2aaQb%2Fimage.png?alt=media&#x26;token=4f92d358-cc70-4cac-a61d-4b0209d53fea" alt=""><figcaption></figcaption></figure>

<details>

<summary>I received an error "Incompatible recipient group type"</summary>

This error occurs when you select a recipient group that is not optimized for a Portable Media Attack.

**Solution:**

Navigate to **Users -> Recipient Groups -> Select "New Group"**

Enter the group name, and associated client:

![](https://3536856424-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FVYPsDfg76rUuy4DWfSsJ%2Fuploads%2FBlHQcjGMbTKrco7DnWqc%2Fimage.png?alt=media\&token=6c282af0-6c7d-4896-a29f-94f03b3e93a1)

Ensure to enable the check box for "**Portable Media Attack**" and specify the number of items you will be loading the files on.

</details>

**Download Files:**

* Navigate to **Results -> Summary -> Select "Download Files"**

<figure><img src="https://3536856424-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FVYPsDfg76rUuy4DWfSsJ%2Fuploads%2FpuvvtK99MMYpfncIEST0%2Fimage.png?alt=media&#x26;token=53524220-435a-427c-9fed-075bdc37b502" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
To address the dynamic nature of payload creation, note that these file-based attack files are not signed by code signing certificates and may trigger antivirus alerts. To mitigate this, ensure to whitelist these files by their path for testing purposes. Additionally, update the Group Policy Object to apply these changes for the company-wide simulation.

\
Please refer to our guide on [**File Attack Whitelisting**](https://wiki.lucysecurity.com/guides/whitelisting-a-lucy-server/file-attack-whitelisting)
{% endhint %}

#### Upload Files to Portable Media:

* Once these files are downloaded, they can be extracted from their zip file.
* Place each file on an individual Portable Media device.
* Distribute these Portable Media devices among your organization.

#### Start Campaign:

* Start the campaign and wait for the configuration checks to complete

<figure><img src="https://3536856424-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FVYPsDfg76rUuy4DWfSsJ%2Fuploads%2FOmzdnre1eAvN05xUz4Eb%2Fimage.png?alt=media&#x26;token=1cc8aa15-7f0e-42bc-a014-c57688924db7" alt=""><figcaption></figcaption></figure>

* When the campaign starts, LUCY will wait for incoming requests from the executed files.

***

### Payload Execution Process

The Portable Media attack uses a Console Post to run `ipconfig` and `whoami` commands. It aims to find users accessing unknown media and executing the payload, likely named "Yearly Bonus Report."

{% hint style="warning" %}
Portable Media Attacks are not classified as Keyloggers and will not run automatically.&#x20;
{% endhint %}

#### Payload Data Received

After a user has successfully executed the file, Lucy will capture the output data and display a success metric on the Summary Dashboard:

<figure><img src="https://3536856424-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FVYPsDfg76rUuy4DWfSsJ%2Fuploads%2FYqL9Dzb7IL8SfzAEZ43j%2Fimage.png?alt=media&#x26;token=4759ab1f-ddfd-43eb-baba-b876e5fa6259" alt=""><figcaption></figcaption></figure>

* To observe the output from the file execution, navigate to **Results -> Statistics -> Collected Data**
* Click the **"command\_line\_output.txt"** to view the output data

<figure><img src="https://3536856424-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FVYPsDfg76rUuy4DWfSsJ%2Fuploads%2F7YLEcuKbQqtlpvtivKPB%2Fimage.png?alt=media&#x26;token=500996e9-b549-4f0b-8f2c-265642b21e23" alt=""><figcaption></figcaption></figure>

#### Example Output:

```bash
[ipconfig]

Windows IP Configuration


Ethernet adapter Ethernet0:

   Connection-specific DNS Suffix  . : localdomain
   IPv4 Address. . . . . . . . . . . : 10.0.0.25
   Subnet Mask . . . . . . . . . . . : 255.255.255.0
   Default Gateway . . . . . . . . . : 10.0.0.2

Ethernet adapter Bluetooth Network Connection:

   Media State . . . . . . . . . . . : Media disconnected
   Connection-specific DNS Suffix  . : 

[whoami]
visvang\nick
```

***
