validates_confirmation_of (ActiveRecord::Validations::ClassMethods)

    # File lib/active_record/validations.rb, line 391
          def validates_confirmation_of(*attr_names)
            configuration = { :message => ActiveRecord::Errors.default_error_messages[:confirmation], :on => :save }
            configuration.update(attr_names.extract_options!)

            attr_accessor(*(attr_names.map { |n| "#{n}_confirmation" }))

            validates_each(attr_names, configuration) do |record, attr_name, value|
              record.errors.add(attr_name, configuration[:message]) unless record.send("#{attr_name}_confirmation").nil? or value == record.send("#{attr_name}_confirmation")
            end
          end