32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
|
# File 'lib/omniauth/strategies/cmu.rb', line 32
def raw_info
if @raw_info.nil?
username = (request)
andrew_id = username.match(/^(.*)@/)[1]
attrs = lookup_andrew_id andrew_id
@raw_info = {
:username => andrew_id,
:name => attrs[:cn],
:email => attrs[:mail],
:nickname => attrs[:nickname],
:first_name => attrs[:givenname],
:last_name => attrs[:sn],
:class => attrs[:cmustudentclass],
:department => attrs[:cmudepartment],
:location => attrs[:cmucampus],
:ldap_attrs => attrs
}
end
@raw_info
end
|