default value for attribute in model

If you want to run some code after the record was found in DB, take a look at after_find and after_initialize callbacks.

class MyClass   def initialize (params=nil)     super(params)     @allow_validation = true   end

  def after_initialize     @allow_validation = true   end end

But I would recommend to use some other method to avoid validation.

Take a look at Acts As Authenticated plugin and Login Engine. Those should contain ready solutions for that problem.