You're not allowed to insult anyone, https://www.gesetze-im-internet.de/stgb/__185.html , though the term "insult" is not nearly as broadly defined as in everyday speech. The law dates back to the 18th century, and has largely been unchanged for 150 years. I really don't understand the recent outrage over these and other laws. We have been fine.
More background: https://de.wikipedia.org/wiki/Beleidigung_(Deutschland)