It emulates a network and triks the computer to send the traffic by giving it an IP address. In other words it plays you ISP.
This requires a web browser to be running behind that locked screen which is a classic lunch scenario
Your cookies to log in on Facetube or your favorite pornsite or Internet shop can be stolen in under one minute and then the hackers can use your ID.
It is called the poison tap.
The PoisonTap, which is made of a £4 Raspberry Pi Zero microcomputer and a USB cable, emulates an internet connection to hijack all of a computer’s internet traffic, stealing the data used to log in to websites like Facebook and Gmail.
https://www.youtube.com/watch?v=Aatp5gCskvk
So that makes me wonder:
WTH did the NSA spend all those tax money on supercomputers?