There are different ways to define “legal”, but one common definition is: of or relating to law or the processes of law. Another definition is: conforming to or permitted by law or established rules.