














































































Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Community
Ask the community for help and clear up your study doubts
Discover the best universities in your country according to Docsity users
Free resources
Download our free guides on studying techniques, anxiety management strategies, and thesis advice from Docsity tutors
The process of customizing LON-CAPA's Perl modules (localauth.pm, localenroll.pm, and localstudentphoto.pm) to integrate with institutional systems. It covers setting domain configurations for user authentication, password policies, and course owner password changes. The document also discusses IP-based access control and institutional directory searches, as well as domain-wide options for user creation.
What you will learn
Typology: Study notes
1 / 86
This page cannot be seen from the preview
Don't miss anything!
LON-CAPA Group
Michigan State University
1 Introduction
The Domain Coordination Manual includes both a description of tasks which require stan- dard LON-CAPA interaction via a web browser, with the Domain Coordinator role active, but also tasks which require command line access to the primary library server in a domain. In some cases one individual may complete both these types of task, whereas in others a separate Systems Administrator may need to be called upon for tasks completed from the command line. With the Domain Coordinator role active, the Main Menu provides a Domain Coordina- tor with access to the functionality needed to complete the routine tasks which a Domain Coordinator carries out, including creation of courses, approval of course requests, and as- signment of author roles. Courses can be created interactively by completing a web form or can be created in batch mode by uploading a file containing course specifications for one or more courses. The right to submit course requests via a web form may also be granted to groups of users, and requests can be set to be processed automatically, or require Domain Coordinator approval. Addition of users/roles can similarly be carried out interactively, or by uploading a text file of users. The Domain Coordinator may also periodically need to modify domain settings via the Domain Configuration menu. LON-CAPA provides hooks to permit integration with institutional information systems to support the following procedures:
There are three perl modules included in LON-CAPA (localauth.pm localenroll.pm, and localstudentphoto.pm all located in /home/httpd/lib/perl ) which need to be customized to provide integration with institutional systems. Although customization and testing will involve a systems administrator, and program- mer(s) at an institution, a Domain Coordinator is likely to be involved in the design and testing phases of the integration, if not in the actual implementation. Set-up of a standalone LON-CAPA instance on a separate server is advised for the purposes of implementing and testing institutional integration, before enabling the new functionality on the production system. Besides the integration described above, customization of localenroll.pm is also needed (at present) to define the titles used for official course categories (e.g., Year, Semester, Department, Number) which can be used as filters when searching the Course/Community Catalog.
LON-CAPA installation and/or update will provide unmodifed copies of the three cus- tomizable files in /home/httpd/lib/perl, each with -std appended, i.e., localauth-std.pm, localenroll-std.pm, and localstudentphoto-std.pm. These files receive updates when ./UP- DATE is run to update a LON-CAPA installation to a newer version, while their customized equivalents will be left untouched. If you have previously customized localenroll.pm it is recommended that you compare the contents of localenroll.pm and localenroll-std.pm after an update to see if there are new subroutines (which exist as stubs in localenroll-std.pm) which can be copied to your custom localenroll.pm and later customized, should you wish to use that functionality.
2 Domain Configuration
Log-in Service If your domain has more than one server you have the option to configure whether any of the servers will redirect to another server whenever the log-in page is requested. This can be useful if you maintain a portal or “Load Balancer” server which forms your institution’s gateway to LON-CAPA. You can specify the path to which the user should be redirected, and also whether log-in page requests from specific IP addresses should be exempt from the redirection. The exemption is useful if you run a monitoring script which tests log-in, course display, and logout periodically for each of your LON-CAPA servers.
Log-in Page Items If your domain only has one LON-CAPA server, or you have multiple servers and will display their log-in pages, their appearance can be customized as follows:
Note: logos displayed in the login page configuration panel are scaled down from the full size used in the log-in page itself.
The following elements are configurable:
For a LON-CAPA node configured to support Single Sign On (SSO), e.g., by operating as a Shibboleth SP, entries in Apache config files (loncapa apache.conf, if Shibboleth) will cause display of an SSO login page whenever a user accesses /adm/roles without a cookie for an unexpired LON-CAPA session. If it is preferred instead to display /adm/login configured to offer dual SSO log-in (e.g., Shibboleth), and non-SSO login (i.e., LON-CAPA), that will be set via the “Dual login: SSO and non-SSO options” section. Check the “Yes” radio button for each of the domain’s servers which will offer dual login and then set:
The value in the URL field will be /adm/sso for Shibboleth, and an uploaded image file will provide the button to be clicked to load /adm/sso (i.e., to prompt an SSO login). The alt and title attributes for the button can also be set. With this in effect the LON-CAPA login page /adm/login will display the following:
If the SSO service is something other than Shibboleth (e.g., CAS or Sentinel) and the PerlVar lonOtherAuthenUrl has been set to a preferred URL (e.g., /adm/sentinel), then the URL item in the SSO entry in the dual login options should be set to that same preferred URL. Note: if the original page request by an unauthenticated user included a query string containing role and symb (i.e., the unique resource instance identifier) then they will be stored in a token file on the server, for access later to support deep-linking.
LON-CAPA will send automatic e-mail to administrators/support staff under certain cir- cumstances. The contact information data table can be used to provide e-mail addresses for receipt of these e-mails and to configure which types of e-mail should be sent to each address. The types of e-mail are:
Definition of the default Admin e-mail address and the default Support e-mail address saved from the “Contact Information” screen supercede any definitions made when ./UPDATE is run to update to a new version of LON-CAPA. Addresses entered the first time ./UPDATE was run on the primary library server for the domain (i.e., when LON-CAPA was first installed) will continue to apply until the first “Save” of the Contact Information settings has occurred in the domain. Three additional settings allow you to specify:
Default color schemes can be set for the domain for four types of user context:
In each case the following can be set or modified:
Individual users can override any default settings you establish for the domain via the “Change Color Scheme” link in their individual Preferences screen. In the absence of individ- ual preferences, any domain defaults you set will be used whenever users from your domain are using LON-CAPA, regardless of which domain owns the server hosting the session.
Prior to LON-CAPA 2.7, default language and authentication type/argument were defined in the domain’s entry in the domain.tab file. Those settings will continue to be used by servers in your domain until you have displayed and saved the Default authentication, language, timezone data table. Once that has been done, whenever values need to be determined for these settings in the domain they will be retrieved from the configuration.db file on the primary library server in your domain, which is where information saved from the “Domain Configuration” data tables is stored. Any information in the domain.tab file will no longer be consulted, except by servers running pre-2.7 versions of LON-CAPA. Default domain configurations can be assigned for:
Institutional user types can also be defined for the domain via the same screen. Prior to LON-CAPA 2.11, institutional user types were defined in the &inst usertypes subroutine in localenroll.pm, which would be customized for consistency with types defined in institutional data feeds. Setting of user types via the Domain Configuration web GUI supersedes use of localenroll::inst usertypes(). Items that can be set are:
on the log-in page. If the information submitted via the web form matches that stored in LON-CAPA for that user (and the user’s authentication type is “internal”), then an e-mail will be sent to the user’s e-mail address, containing a time-limited link, which when followed will display a second web form, in which the user enters e-mail address, username, e-mail address, and a new password. Starting with LON-CAPA 2.11.3 this procedure can be customized in the following ways:
If “Institutional Types” (e.g., faculty, student etc.) have been defined for a domain then some of the customizations can be made dependent on a user’s institutional type. Encryption of Stored Passwords
Rules for LON-CAPA Passwords
Starting with LON-CAPA 2.11.3 requirements can be set for password length, whether special characters or mixed case are required, and how many (if any) previous passwords to save for a user (disallow reuse). Course Owner Changing Student Passwords Starting with LON-CAPA 2.11.3 a domain can be configured to allow a course owner to change a student’s password, if the following conditions are met:
If “Institutional Types” (e.g., faculty, staff, student etc.) have been defined for a domain then which course owners may change student passwords can be restricted to specific types. In addition, which students may have their passwords changed can also be restricted to specific types. The default is to not allow Course owners to change a student’s password.
By default, each user in your domain can create blogs, a personal information page, and store files in an individual portfolio space. Students can submit items from their portfolio to meet the requirements of assignments in their courses. You can choose to disable personal information pages, blogs and/or portfolios for different groups of users defined for your domain (e.g., Faculty, Adjunct, Staff, Student). If the “Modify User” utility in User Management is used to explicitly set availability of these tools for a particular user, that will override the corresponding settings determined by the user’s affiliation. If you choose to enable portfolios, default quotas (in MB) can similarly be set to vary by institutional affiliation. If a user is affiliated with more than one group, whichever default quota is largest for the different groups is the one which applies. Institutional types are defined in the “Institutional user types” section on the “Default authentication, language, timezone, portal, types” screen. If no types have been defined, then a single default quota will apply for all users from the domain. Default portfolio quotas which can be set for users in your domain will be overridden by any quota you set for an individual user via: the “Modify User” utility. Additional options for authoring spaces can be set for the various user types: (a) whether webDAV is active, and (b) the default quota for Authoring Space. These only come into effect for a particular user, when an author and/or one or more co-author roles have been assigned to a user to provide access to one or more Authoring Spaces.
To accommodate use of LON-CAPA within a dedicated Computer Based Testing Facility (CBTF), a domain configuration is available to set IP-based restrictions on availability of student roles in course(s) and access to LON-CAPA tools used for communication and col- laboration. This complements domain settings in the “Blogs, personal web pages, webDAV/quotas, portfolios” section 2.6 which apply by default, regardless of a user’s IP address, to specific types of user (e.g., Student, Staff etc.). IP-based access controls set at a domain level also complement time-limited blocks a Course Cordinator can set in a course via Settings > Content Settings > Blocking Communication/Resource Access, some of which can impact functionality in other courses, e.g.,, Chat, Messaging, Portfolio and Blogs. Configuration of IP-based access control in a domain supports multiple access control items, and each item in use will be assigned the following:
due to IP block”. Lastly, if the “Ask helpdesk form settings” for the domain include the“Cc e-mail” field as an optional field, that will not apply in the case where IP- based blocking of “Messaging” is in effect for a logged-in user who is completing the help form.
Accordingly, either the domain should be configured so LON-CAPA sessions for the domain’s users may only be hosted on the institution’s own server(s), see the “User session hosting/offloading” section 2.25, or web browsers in the location (or local net- work) should be ”locked down” such that the only LON-CAPA servers which may be contacted by browsers in the location are servers in the institution’s domain(s).
A LON-CAPA server requires a static IP address, and the hostname included in the hosts.tab entry for the server should resolve to that IP address. If the server is part of the LON-CAPA network, the server will need to support connections from other servers for both “internal” communication via the dedicated LON-CAPA port as well as requests to standard web ports when replicating content. Consequently, in order to run LON-CAPA server(s) behind a Web Application Firewall (WAF), or Reverse Proxy, different hostname(s), or alias(es) to the default hostname in /home/httpd/lonTabs/hosts.tab must be requested by users’ web browsers when accessing LON-CAPA pages from a domain’s server(s) via a WAF.
If VPN users will not use WAF, but other users will, then the following are needed:
LON-CAPA provides a mechanism to search for users by complete username, last name, or last name,first name (or fragments of each). Accounts within the LON-CAPA domain itself can be searched, or alternatively, an institutional directory may be searched, if you are able to implement a conduit to directory information to support such searches. This will be done by customizing the &get userinfo() routine in localenroll.pm. This routine has a dual role in LON-CAPA. Not only will it support searches where the user is not excatly known, but it can also be used to retrieve institutional records for a specific username or student/employee ID. This latter mode of use is appropriate when adding a new user to LON-CAPA. Settings for directory searches apply either to institutional directory searches or to LON- CAPA domain searches.
In the case of a “contains” type search at least three characters must be entered by the user as the search term. Searches are case insensitive.
Identity management in a LON-CAPA domain is dependent on settings made for user cre- ation and user modification. Of particular concern is the potential for assignment of user- names in a format used by your institution when the username does not yet exist. In such a case, authentication is likely to be set to be “internal”, and should a real user be created in the future, and be enrolled in a course by auto-enrollment, the user would either be unable to authenticate (using LON-CAPA log-in page), or would be authenticated by SSO, and have access to the original user’s roles and associated information. It is important therefore to establish format rules for new usernames so the only users created with institutional-type usernames are the real users themselves with the appropriate authentication type (Kerberos or localauth). Even without format rules, the Domain Coor- dinator can set who can create new users, and the authentication types that may be set in different context. The domain-wide options available for user creation are:
The format rules themselves are defined by customizing the following routines in localen- roll.pm:
When enforced the user name and ID rules require that if a username and/or ID which matches the format for an active rule is to be used in LON-CAPA, they must exist in the institutional directory. If they exist, the corresponding user information (first name, middle name, last name, e-mail address) will be used when creating the new user account. If they do not exist, account creation will not occur.