Use one of the perfect setup howtos, the postfix configuration enables sasl authentication and configures postfix to relay only for 127.0.0.1.