I think today it's not in the name of security but to deal with ridiculous levels of ai scraping.
Sure they also just want everyone to make accounts anyway so it's absolutely a convenient excuse, but it's also real that ais are killing all public sites with constant massive scraping.
There was a thing recently about the kernel gitweb that ais are just clobbering because of the way they stupidly hit every possible valid url, and on a gitweb instance that results in a gobjillion duplicate clones of the entire universe for every tiny commit.