Added simple authorize script, extracted config variables