There are multiple definitions - click on the translation that matches your context.

违反

动词

full

offend

verb

Definitions of offend

English

to breach a rule, regulation, or condition etc

In these cases, the Company may dismiss the offending employee.

English

to cause someone to feel upset or annoyed etc

The Government is not likely to offend unionist sensibilities.

English

to commit a crime or commit an illegal act

Those who do offend will face the consequences of their actions - and prison will still be a major part of that.