Running commands on multiple Meterpreters

Yup! We can run Meterpreter commands on numerous open Meterpreter sessions using the -c switch with the sessions command, as shown in the following screenshot:

We can see that Metasploit has intelligently skipped a non-Meterpreter session, and we have made the command run on all the Meterpreter sessions, as shown in the preceding screenshot.

Get Mastering Metasploit - Third Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.