It's possible, but would you really be surprised if you installed it and later discovered it contained spyware/malware?
I would be surprised if I got something from a well-known, reputable company that turned out to be malware. Something from an Internet rando? Not so much.
Basically, yes. I think we've all come to expect freeware to also be free (libre) software. I certainly am in favor of free software as well, but I think that we assume at this point that if you aren't making money from it and you aren't releasing the code, you have something to hide. However, the interesting thing is that back in the day, shareware was often closed source unless you paid to register it, in which case you got access to the code (depending on the publisher, obviously).
I don’t recall any shareware back then having open source access to the dos,windows programs just floppy disk shared binaries. The reality was before the always on internet and broadband speeds, malware was very rare, but viruses were ubiquitous on shared floppies but more of nuisance. Floppies with shareware by named distributors we’re unlikely to have virus unlike online boards or floppies handed around student to student back in the day.
I just got done reading a book called "Shareware Heroes" that mentioned various shareware apps providing source code to users who registered. The free versions never had source provided; the source was advertised as a perk for paid users. It's different than what we expect today, but honestly not the worst business model out there.