Sincerely, why do you think it illegal? Aren't they allowed to speculatively register domains to resell?
Please understand this is a sincere question. I'm asking because I think it's legal. If it's illegal, I want to know about that, and especially how the law might view a register's squatting and an individual's squatting differently.
Edit: Just so it's clear, by "register" I mean truly register the domain for a year -- not "taste" it for a few days and then cancel the registration, if that is even still allowed.
They are not selling them on behalf of anyone - they, the registrar, are illegally marking them up.