see: https://github.com/omniauth/omniauth-ldap
PlaceOS::Model::LdapAuthentication
Inherits PlaceOS::Model::Timestamps < PlaceOS::Model::ModelBase < PlaceOS::Model::Associations < Neuroplastic < PgORM::Base < PgORM::Validators < PgORM::Table < PgORM::Persistence < PgORM::Associations < ActiveModel::Callbacks < ActiveModel::Validation < ActiveModel::Model < DB::Mappable < DB::Serializable < YAML::Serializable < JSON::Serializable < Reference < Object
see: https://github.com/omniauth/omniauth-ldap
Constants
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
macro level key => type
see: https://github.com/omniauth/omniauth-ldap
Constructors
see: https://github.com/omniauth/omniauth-ldap
Deserializes the given JSON in string_or_io into
an instance of self, assuming the JSON consists
of an JSON object with key root, and whose value is
the value to deserialize. Will not deserialise from
fields with mass_assign: false
class User < ActiveModel::Model
attribute name : String
attribute google_id : UUID, mass_assign: false
end
User.from_json(%({"main": {"name": "Jason", "google_id": "f6f70bfb-c882-446d-8758-7ce47db39620"}}), root: "main") # => #<User:0x103131b20 @name="Jason">
see: https://github.com/omniauth/omniauth-ldap
Serialize from a trusted JSON source
Serialize from a trusted YAML source
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Initialize PlaceOS::Model::LdapAuthentication from HTTP::Params.
Class methods
Returns all attribute keys.
Changefeed at row (if id passed) or whole table level.
Returns a ChangeFeed instance which can be used to invoke async callbacks via on or
use blocking Iterator via each method.
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Instance methods
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Generate code to apply default values
Assign to multiple attributes.
Assign to multiple attributes via HTTP::Params.
Assign to multiple attributes from a model object
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Assign each field from JSON if field exists in JSON and has changed in model
see: https://github.com/omniauth/omniauth-ldap
Uses the YAML parser as JSON is valid YAML
Returns a Hash of all attribute values
Returns a NamedTuple of all attribute values.
auth_method getter
auth_method setter
NOTE: use getter / getter! (not property / property!) so that the
setter defined later in __create_initializer__ is the only setter on
the field. Crystal's overload resolution silently fails to replace a
property-defined setter with one of identical signature for generic
types (e.g. Set(String)?, Array(String)?, String | Array(String)),
although it does work for non-generic ones like String?. Defining the
setter only once via __create_initializer__ ensures change tracking,
sanitization, and custom setter blocks run uniformly across all types.
see: https://github.com/omniauth/omniauth-ldap
Returns a Tuple of the previous and the current value of an instance variable if it has changed
see: https://github.com/omniauth/omniauth-ldap
One of "plain", "ssl", "tls"
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Include auth_method in the set of changed attributes, whether it has changed or not.
authority_id getter
authority_id setter
see: https://github.com/omniauth/omniauth-ldap
Returns a Tuple of the previous and the current value of an instance variable if it has changed
see: https://github.com/omniauth/omniauth-ldap
authority_id's default value
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Include authority_id in the set of changed attributes, whether it has changed or not.
base getter
base setter
NOTE: use getter / getter! (not property / property!) so that the
setter defined later in __create_initializer__ is the only setter on
the field. Crystal's overload resolution silently fails to replace a
property-defined setter with one of identical signature for generic
types (e.g. Set(String)?, Array(String)?, String | Array(String)),
although it does work for non-generic ones like String?. Defining the
setter only once via __create_initializer__ ensures change tracking,
sanitization, and custom setter blocks run uniformly across all types.
see: https://github.com/omniauth/omniauth-ldap
Returns a Tuple of the previous and the current value of an instance variable if it has changed
see: https://github.com/omniauth/omniauth-ldap
BaseDN such as dc=intridea, dc=com
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Include base in the set of changed attributes, whether it has changed or not.
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
bind_dn getter
bind_dn setter
see: https://github.com/omniauth/omniauth-ldap
Returns a Tuple of the previous and the current value of an instance variable if it has changed
see: https://github.com/omniauth/omniauth-ldap
bind_dn and password are the default credentials to perform user lookups
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Include bind_dn in the set of changed attributes, whether it has changed or not.
Check if any attributes have changed.
Returns a Hash with all changed attributes.
Serialize the set of changed attributes to JSON.
Serialize the set of changed attributes to JSON.
see: https://github.com/omniauth/omniauth-ldap
Serialize the set of changed attributes to YAML.
Serialize the set of changed attributes to YAML.
Reset changes for all attributes.
created_at getter
Setters
created_at setter
NOTE: use getter / getter! (not property / property!) so that the
setter defined later in __create_initializer__ is the only setter on
the field. Crystal's overload resolution silently fails to replace a
property-defined setter with one of identical signature for generic
types (e.g. Set(String)?, Array(String)?, String | Array(String)),
although it does work for non-generic ones like String?. Defining the
setter only once via __create_initializer__ ensures change tracking,
sanitization, and custom setter blocks run uniformly across all types.
see: https://github.com/omniauth/omniauth-ldap
Returns a Tuple of the previous and the current value of an instance variable if it has changed
see: https://github.com/omniauth/omniauth-ldap
created_at's default value
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Include created_at in the set of changed attributes, whether it has changed or not.
filter getter
filter setter
see: https://github.com/omniauth/omniauth-ldap
Returns a Tuple of the previous and the current value of an instance variable if it has changed
see: https://github.com/omniauth/omniauth-ldap
LDAP filter like: (&(uid=%{username})(memberOf=cn=myapp-users,ou=groups,dc=example,dc=com))
Can be used instead of uid
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Include filter in the set of changed attributes, whether it has changed or not.
host getter
host setter
NOTE: use getter / getter! (not property / property!) so that the
setter defined later in __create_initializer__ is the only setter on
the field. Crystal's overload resolution silently fails to replace a
property-defined setter with one of identical signature for generic
types (e.g. Set(String)?, Array(String)?, String | Array(String)),
although it does work for non-generic ones like String?. Defining the
setter only once via __create_initializer__ ensures change tracking,
sanitization, and custom setter blocks run uniformly across all types.
see: https://github.com/omniauth/omniauth-ldap
Returns a Tuple of the previous and the current value of an instance variable if it has changed
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Include host in the set of changed attributes, whether it has changed or not.
id getter
id setter
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Returns a Tuple of the previous and the current value of an instance variable if it has changed
see: https://github.com/omniauth/omniauth-ldap
id's default value
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Include id in the set of changed attributes, whether it has changed or not.
see: https://github.com/omniauth/omniauth-ldap
name getter
name setter
NOTE: use getter / getter! (not property / property!) so that the
setter defined later in __create_initializer__ is the only setter on
the field. Crystal's overload resolution silently fails to replace a
property-defined setter with one of identical signature for generic
types (e.g. Set(String)?, Array(String)?, String | Array(String)),
although it does work for non-generic ones like String?. Defining the
setter only once via __create_initializer__ ensures change tracking,
sanitization, and custom setter blocks run uniformly across all types.
see: https://github.com/omniauth/omniauth-ldap
Returns a Tuple of the previous and the current value of an instance variable if it has changed
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Include name in the set of changed attributes, whether it has changed or not.
password getter
password setter
see: https://github.com/omniauth/omniauth-ldap
Returns a Tuple of the previous and the current value of an instance variable if it has changed
see: https://github.com/omniauth/omniauth-ldap
NOTE: use getter / getter! (not property / property!) so that the
setter defined later in __create_initializer__ is the only setter on
the field. Crystal's overload resolution silently fails to replace a
property-defined setter with one of identical signature for generic
types (e.g. Set(String)?, Array(String)?, String | Array(String)),
although it does work for non-generic ones like String?. Defining the
setter only once via __create_initializer__ ensures change tracking,
sanitization, and custom setter blocks run uniformly across all types.
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Include password in the set of changed attributes, whether it has changed or not.
see: https://github.com/omniauth/omniauth-ldap
port getter
port setter
NOTE: use getter / getter! (not property / property!) so that the
setter defined later in __create_initializer__ is the only setter on
the field. Crystal's overload resolution silently fails to replace a
property-defined setter with one of identical signature for generic
types (e.g. Set(String)?, Array(String)?, String | Array(String)),
although it does work for non-generic ones like String?. Defining the
setter only once via __create_initializer__ ensures change tracking,
sanitization, and custom setter blocks run uniformly across all types.
see: https://github.com/omniauth/omniauth-ldap
Returns a Tuple of the previous and the current value of an instance variable if it has changed
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Include port in the set of changed attributes, whether it has changed or not.
see: https://github.com/omniauth/omniauth-ldap
Reset each attribute to their previous values and clears all changes.
see: https://github.com/omniauth/omniauth-ldap
uid getter
uid setter
NOTE: use getter / getter! (not property / property!) so that the
setter defined later in __create_initializer__ is the only setter on
the field. Crystal's overload resolution silently fails to replace a
property-defined setter with one of identical signature for generic
types (e.g. Set(String)?, Array(String)?, String | Array(String)),
although it does work for non-generic ones like String?. Defining the
setter only once via __create_initializer__ ensures change tracking,
sanitization, and custom setter blocks run uniformly across all types.
see: https://github.com/omniauth/omniauth-ldap
Returns a Tuple of the previous and the current value of an instance variable if it has changed
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Include uid in the set of changed attributes, whether it has changed or not.
updated_at getter
updated_at setter
NOTE: use getter / getter! (not property / property!) so that the
setter defined later in __create_initializer__ is the only setter on
the field. Crystal's overload resolution silently fails to replace a
property-defined setter with one of identical signature for generic
types (e.g. Set(String)?, Array(String)?, String | Array(String)),
although it does work for non-generic ones like String?. Defining the
setter only once via __create_initializer__ ensures change tracking,
sanitization, and custom setter blocks run uniformly across all types.
see: https://github.com/omniauth/omniauth-ldap
Returns a Tuple of the previous and the current value of an instance variable if it has changed
see: https://github.com/omniauth/omniauth-ldap
updated_at's default value
see: https://github.com/omniauth/omniauth-ldap
see: https://github.com/omniauth/omniauth-ldap
Include updated_at in the set of changed attributes, whether it has changed or not.
Validate that all non-nillable fields have values.