Earlier quoted context omitted.
In the US permission is required to make copies, prepare derivative works, distribute copies, publicly perform the work, or publicly display the work [1]. [1] https://www.law.cornell.edu/uscode/text/17/106
Right, the question is, when my computer requests a file from your computer, which one of us is "making a copy" ? It becomes less ambiguous to ask who is doing the publishing. In a physical analogy, if someone is selling bootleg DVDs on the street, I don't think anyone ever got busted for being a customer.
If the case of computer programs making such a copy does not require permission because of 17 USC 117 [1], which says that the owner of a copy of a computer program can make copies or adaptations if they are created as an essential step in utilizing the program and they are used in no other manner.
For digital downloads other than computer programs 17 USC 117 does not apply, and so copying to RAM to use the download would in theory be infringement. You probably won't get sued over it of course so its nothing to lose sleep over.