Added environmental key support