It has long been a policy of Google that engaging in cloaking behavior can get your site penalized, banned, or worse.
One webmaster, during John Mueller’s 09/17/2921 hangout, asked about cloaking techniques they were using for their site.
John explained, unequivocally, that the webmaster should not be engaging in cloaking or cloaking behavior.
The webmaster was also concerned about their paywall. John said that they just need to mark up the paywall using paywall structured data so Google can see that’s actually what’s being served.
Basically, the overall rule is that you must show users, even other users from the same location, the same content that you would show Googlebot.
This discussion occurs at approximately 28:48 in the video: