The bug that caused pets to not suffer environmental damage or damage from enemy entities has been fixed; if required in the future, an option to activate and deactivate that feature could be added.
Protection between players and pets: they don't harm each other.