Page History
...
- Install OpenAthens software
- Download the software from https://download.openathens.net and run the installer.You will need the same credentials you use to access the publisher dashboard
- Download the software from https://download.openathens.net and run the installer.You will need the same credentials you use to access the publisher dashboard
Generate or install a metadata signing certificate - most federations allow these to be self-signed and last several years. To generate a key-pair, run the script in the keys folder:
Code Block C:\Program Files (x86)\Eduserv\OpenAthens.Net\keys\gen_self_signed_cert.bat
For details, or to import a pre-existing key pair, see: Install metadata signing certificates on .NET
Anchor metadatareturn metadatareturn - If you have not already done so, create an application in the publisher dashboard. You will have the opportunity to paste in the signing certificate you generated in the previous step.when you set it up
- If this is for an existing application, open the application details and go to the getting started tab of the application details to add this certificate.
- If this is for an existing application, open the application details and go to the getting started tab of the application details to add this certificate.
The dashboard will provide text to copy and paste in these two areas of your
web.config
file:Referencing the
OpenAthens.Net.dll
assembly in the<compilation>
section, e.g:Code Block language xml <compilation> <assemblies> <add assembly="OpenAthens.Net,Version=1.0.0.0, Culture=neutral, PublicKeyToken=17390934318f9b06"/> <add assembly="atacama.net, Version=2.1.3.0, Culture=neutral, PublicKeyToken=6E679382149F5665"/> </assemblies> </compilation>
Referencing your OpenAthens configuration published by the publisher dashboard in the
<configuration>
section (in a single line), e.g:Code Block language xml <openAthens atacamaConfig="https://sp.openathens.net/configurations?id=XxXxXxXxXxXxXxXxXx" accessKey="xxxxxxx-xxxxxx-xxxxxx-xxxxxx" logConfig="C:\Program Files (x86)\Eduserv\OpenAthens.Net\conf\defaultLogConfig.xml"/>
Still in the
web.config
file, define anopenAthens
section name under<configSections>
- e.g:Code Block <configSections> <section name="openAthens" type="Eduserv.OpenAthens.OpenAthensConfigSection"/> </configSection>configSections>
You can then define the OpenAthens enabled area in the
<configuration>
section of yourweb.config
file, e.g:Code Block language xml <location path="Protected.aspx"> <openAthens> <authentication enabled="true"/> </openAthens> <system.web> <authorization> <deny users="?"/> </authorization> </system.web> </location>
(The enabled section could be the whole restricted section of your site, but might just be necessary to integrate part of your existing authorisation section, depending on whether your existing code will handle returning the user to the target page they were originally trying to access)
Next integrate OpenAthens SP with the ASP.NET pipeline. How this is done will depend on the version of IIS and which mode it is in. We will assume integrated mode here, as that is most common, and that it is set such that all requests are channelled through the pipeline. In such cases you need only add a line to your
web.config
in the<system.webServer>
section to include OpenAthens SP, e.g:Code Block xml xml <system.webServer> <modules runAllManagedModulesForAllRequests="true"> <add name="OpenAthensServerModule" type="Eduserv.OpenAthens.ServerModule"/> </modules> </system.webServer>
If you need to use classic mode, see: Integrating OpenAthens with the ASP.NET pipeline in IIS classic mode
- Check folder permissions to ensure the IIS user can access them:
- OpenAthens software, typically in
C:\Program Files (x86)\Eduserv\OpenAthens.Net
. The IIS_USERS group will need to list, read and execute. - Program data, typically in
C:\ProgramData\Eduserv\OpenAthens\
. The IIS_USERS group will need modify, read and list.
- OpenAthens software, typically in
Finally, restart IIS to download the configuration from the publisher dashboard and start using it.
Anchor pipeline pipeline
...