Store enum values as string

Do not rely on int value and casting back ints to enum values.
Also actually set the data type accordingly in ReadPasswordJob.