Skip to content

no-tx-origin

Forbids the use of tx.origin.

Examples of incorrect code for this rule:

contract Example {
address public owner;
constructor() {
owner = tx.origin;
}
}