$IN = '/path/to/file'; open IN; while() { next if /^$/; ($key,$value) = split /\s*:\s*/; $hash{uc $key} = $value; }