LF_Mcxixif_ you would need to use the Flarum extension API to disable email and password change, or run custom logic when that happens.
I don't think there's any general-purpose extension that does this.
My Wordpress extension does this to keep Wordpress and Flarum users in sync but unfortunately it's not open-source so I cannot show the full code.