Hendrick/ring-okta


Middleware for integrating Okta and Ring

License: EPL-1.0

Language: Clojure


ring-okta

Build Status

Ring middleware for Okta Single Sign-on.

Installation

Leiningen

[ring-okta "0.1.6"]

Gradle

compile "ring-okta:ring-okta:0.1.6"

Maven

<dependency>
  <groupId>ring-okta</groupId>
  <artifactId>ring-okta</artifactId>
  <version>0.1.6</version>
</dependency

Okta SAML Toolkit Dependency

Since Okta doesn't publish the SAML Toolkit for Java, you must download it here. You then must mvn install it to your local maven repository. Check the project.clj for the version of the SAML Toolkit to download from Okta.

Usage

(ns com.company.core
  (:require [compojure.core :refer :all]
            [compojure.route :as route]
            [ring.middleware.okta :refer [wrap-okta okta-routes]]))

(defroutes company-routes
  (GET "/" [] "<h1>Hello World</h1>")

  okta-routes

  (route/not-found "<h1>Page not found</h1>"))

(def app
  (-> company-routes
      (wrap-okta {:okta-home "https://company.okta.com"})))

Documentation

The documentation is built with codox (lein doc) and published to the gh-pages branch.

Test Coverage

The test coverage summary is built with cloverage (lein cloverage).

Development

As described in Usage above, the Okta SAML Toolkit must be downloaded and installed to your local maven repository. When updating this dependency, here is how you can install the downloaded jar:

$ mvn install:install-file -Dfile=saml-toolkit.jar -DgroupId=com.okta -DartifactId=saml-toolkit -Dpackaging=jar -Dversion=<version> -DcreateChecksum=true -DupdateReleaseInfo=true -DgeneratePom=true -DlocalRepositoryPath=/path/to/localRepo

Generating API Docs

The lein doc command is configured in project.clj to output documentation to ../ring-okta-doc. This should be configured to be the gh-pages branch so the API docs can be hosted on GitHub.

~/code
  |- ring-okta
  |- ring-okta-doc
  ...

Once lein doc is run in ring-okta, you can commit the changes in ring-okta-doc to the gh-pages branch of this repository.

License

Copyright © 2015 Hendrick Automotive Group

Distributed under the Eclipse Public License either version 1.0 or (at your option) any later version.

Project Statistics

Sourcerank 3
Repository Size 162 KB
Stars 10
Forks 1
Watchers 12
Open issues 1
Dependencies 0
Contributors 1
Tags 7
Created
Last updated
Last pushed

Top Contributors See all

Matthew Boston

Packages Referencing this Repo

ring-okta
Ring middleware for Okta Single Sign-on
Latest release 0.1.6-SNAPSHOT - Updated - 10 stars
ring-okta:ring-okta
Ring middleware for Okta Single Sign-on
Latest release 0.1.6 - Updated - 10 stars

Recent Tags See all

v0.1.6 December 02, 2015
v0.1.5 July 17, 2015
v0.1.4 June 16, 2015
v0.1.3 September 26, 2014
v0.1.2 September 19, 2014
v0.1.1 September 10, 2014
v0.1.0 September 09, 2014

Something wrong with this page? Make a suggestion

Last synced: 2016-05-27 14:16:47 UTC

Login to resync this repository