Solidity – Is ‘tx.origin’ Always an Externally Owned Account (EOA)

eoasoliditytx.origin

The Solidity docs on Global Variables say this about tx.origin:

sender of the transaction (full call chain)

But that is a bit vague. Can we always be sure that ts.origin is an externally owned account (EOA)? Are there any edge cases?

Best Answer

It is, tx.origin is the original sender of the call. In a transaction that results in a chain of calls, tx.origin is the EOA that initiated the transaction in the first place (contracts cant initiate transactions on their own) and msg.sender is the last member of the chain (and it can be a contract)

Related Topic