SMB attack on VM

Neil MacKenzie 0 Reputation points
2025-08-04T02:10:10.6566667+00:00

The Windows event viewer is showing lots of SMB logon attempts even though the NSG for the VM is setup to block port 445. How is this happening?

Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
{count} votes

1 answer

Sort by: Most helpful
  1. Andreas Baumgarten 125.2K Reputation points MVP Volunteer Moderator
    2025-08-05T05:30:20.76+00:00

    Hi @Neil MacKenzie ,

    please take a look here: Preventing SMB traffic from lateral connections and entering or leaving the network

    The recommendation is:

    • Block inbound and outbound TCP 445
    • Block inbound and outbound UDP137
    • Block inbound and outbound UDP 138
    • Block inbound and outbound TCP 139

    (If the reply was helpful please don't forget to upvote and/or accept as answer, thank you)

    Regards

    Andreas Baumgarten

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.