To twist by a trick is a legal offence (7)
I believe the answer is:
contort
'to twist' is the definition.
(contorting is a kind of twisting)
'a trick is a legal offence' is the wordplay.
I cannot really understand how this works, but
'trick' could be 'con' (a con is a fraud or trick) and 'con' is present in the answer.
'offence' could be 'tort' (legal term for a type of offence) and 'tort' is present in the answer.
No letters remain.
This explanation may well be incorrect...
'by' acts as a link.
Can you help me to learn more?
(Another definition for contort that I've seen is " Twist out of shape".)