Skip to content

Commit afc42f5

Browse files
authored
Update README.md
Corrected a few minor typographical errors and updated some of the English text to be more clear.
1 parent 05b77e6 commit afc42f5

1 file changed

Lines changed: 23 additions & 24 deletions

File tree

README.md

Lines changed: 23 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,17 @@
55
Add SAML support to your Java applications using this library.
66
Forget those complicated libraries and use that open source library provided and supported by OneLogin Inc.
77

8-
This is the Version 2.0.0, compatible with java6 / java7 / java8.
8+
This is version 2.0.0, compatible with java6 / java7 / java8.
99

10-
The 1.1.2 is consider deprecated. If you used it, we strongly recommend to migrate to that new version.
11-
We rebuilt the toolkit on 2.0.0 so code/settings that you had will not be compatible.
10+
Version 1.1.2 is considered to be deprecated. If you have used it, we strongly recommend that you migrate to the new version.
11+
We rebuilt the toolkit on 2.0.0, so code/settings that you had been using in the previous version will no longer be compatible.
1212

1313

1414
## Why add SAML support to my software?
1515

1616
SAML is an XML-based standard for web browser single sign-on and is defined by
1717
the OASIS Security Services Technical Committee. The standard has been around
18-
since 2002, but lately it is becoming popular due its advantages:
18+
since 2002, but lately it has become popular due to its advantages as follows:
1919

2020
* **Usability** - One-click access from portals or intranets, deep linking,
2121
password elimination and automatically renewing sessions make life
@@ -53,9 +53,9 @@ Key features:
5353

5454
* **saml2int** - Implements the SAML 2.0 Web Browser SSO Profile.
5555
* **Session-less** - Forget those common conflicts between the SP and
56-
the final app, the toolkit delegate session in the final app.
56+
the final app; the toolkit delegates session in the final app.
5757
* **Easy to use** - Programmer will be allowed to code high-level and
58-
low-level programming, 2 easy to use APIs are available.
58+
low-level programming; 2 easy-to-use APIs are available.
5959
* **Tested** - Thoroughly tested.
6060
* **Popular** - OneLogin's customers use it. Add easy support to your java web projects.
6161

@@ -136,16 +136,16 @@ At the Package Explorer, select the jsp-sample project, 2nd bottom of the mouse
136136
Select a [Tomcat Server](http://crunchify.com/step-by-step-guide-to-setup-and-install-apache-tomcat-server-in-eclipse-development-environment-ide/) in order to deploy the server.
137137

138138
## Getting started
139-
### Knowing the toolkit
139+
### Learning the toolkit
140140

141-
The new OneLogin's SAML Java SAML Toolkit contains different folders (core, toolkit, samples) and some files.
141+
OneLogin's new SAML Java SAML Toolkit contains different folders (core, toolkit, samples) and some files.
142142

143143
Let's start describing them:
144144

145145
#### core (com.onelogin:java-saml-core) ####
146-
This folder contains a maven project with the heart of java-saml, classes and methods to handle AuthNRequest, SAMLResponse, LogoutRequest, LogoutResponse and Metadata (low level API). In addition contains classes to load the settings of the toolkit and the HttpRequest class, a framework-agnostic representation of an HTTP request.
146+
This folder contains a maven project with the heart of java-saml, classes and methods to handle AuthNRequest, SAMLResponse, LogoutRequest, LogoutResponse and Metadata (low level API). In addition, it contains classes to load the settings of the toolkit and the HttpRequest class, a framework-agnostic representation of an HTTP request.
147147

148-
In the repo, at *src/main/java* you will find the source, at *src/main/resources/schemas* there are xsd schemas used to validate the SAML messages, at *src/test/java* are the tests for its classes and at *src/test/resources* different settings, SAML messages and certificates used on the junit tests.
148+
In the repo, at *src/main/java* you will find the source; at *src/main/resources/schemas*, there are xsd schemas used to validate the SAML messages; at *src/test/java* are the tests for its classes; and at *src/test/resources* can be found different settings, SAML messages and certificates used by the junit tests.
149149

150150

151151
#### toolkit (com.onelogin:java-saml) ####
@@ -155,7 +155,7 @@ In the repo, at *src/main/java* you will find the source and at *src/test/java*
155155
#### samples (com.onelogin:java-saml-tookit-samples) ####
156156
This folder contains a maven project with a jsp app used to learn how the java-saml toolkit works.
157157

158-
At *java-saml-tookit-jspsample/src/main/webapp* folder we will find several jsp files, each one represent a different endpoint:
158+
Within the *java-saml-tookit-jspsample/src/main/webapp* folder are several jsp files, each one representing a different endpoint:
159159
- *index.jsp* Index of the webapp.
160160
- *dologin.jsp* SP-initiated SSO endpoint.
161161
- *dologout.jsp* SP-initiated SLO endpoint.
@@ -164,7 +164,7 @@ At *java-saml-tookit-jspsample/src/main/webapp* folder we will find several jsp
164164
- *sls.jsp* Service Provider Single Logout Service endpoint.
165165
- *metadata.jsp* Publish SP metadata.
166166

167-
At *java-saml-tookit-jspsample/src/main/resources* folder is the *onelogin.saml.properties* file that contains the SAML settings.
167+
At *java-saml-tookit-jspsample/src/main/resources* folder is the *onelogin.saml.properties* file which contains the SAML settings.
168168

169169
### How it works
170170

@@ -174,9 +174,9 @@ At *java-saml-tookit-jspsample/src/main/resources* folder is the *onelogin.saml.
174174
* [core (com.onelogin:java-saml-core)](https://onelogin.github.io/java-saml/core/index.html)
175175

176176
#### Settings
177-
First of all we need to configure the toolkit. The SP's info, the IdP's info, and in some cases, configure advanced security issues like signatures and encryption.
177+
First of all we need to configure the toolkit. The SP's info, the IdP's info, and in some cases, configuration for advanced security issues, such as signatures and encryption.
178178

179-
All the settings are defined in one unique file, by default the Auth class loads a *onelogin.saml.properties* file with the Auth() method, but if we named it in a differnt way we can use Auth(filename);
179+
All the settings are defined in one unique file; by default, the Auth class loads a *onelogin.saml.properties* file with the Auth() method, but if we named it in a different way, we can use Auth(filename);
180180

181181
Here are the list of properties to be defined on the settings file:
182182
```properties
@@ -359,18 +359,17 @@ We can set a 'returnTo' url parameter to the login function and that will be con
359359
String targetUrl = 'https://example.com';
360360
auth.login(returnTo=targetUrl)
361361
```
362-
The login method can recieve 4 more optional parameters:
363-
- forceAuthn When true the AuthNReuqest will set the ForceAuthn='true'
364-
- isPassive When true the AuthNReuqest will set the Ispassive='true'
365-
- setNameIdPolicy When true the AuthNReuqest will set a nameIdPolicy element.
366-
- stay True if we want to stay (returns the url string) False to execute a redirection to that url (IdP SSO URL)
367-
368-
By default the login method initiates a redirect to the SAML Identity Provider. You can use the stay parameter, to prevent that, and execute the redirection manually. We need to use that
369-
if a match on the future SAMLResponse ID and the AuthNRequest ID to be sent is required, that AuthNRequest ID must be extracted and stored for future validation so we can't execute the redirection on the login, instead set stay to true, then get that ID by
362+
The login method can receive 4 more optional parameters:
363+
- *forceAuthn* When true the AuthNRequest will have the 'ForceAuthn' attribute set to 'true'
364+
- *isPassive* When true the AuthNRequest will have the 'Ispassive' attribute set to 'true'
365+
- *setNameIdPolicy* When true the AuthNRequest will set a nameIdPolicy element.
366+
- *stay* Set to true to stay (returns the url string), otherwise set to false to execute a redirection to that url (IdP SSO URL)
367+
368+
By default, the login method initiates a redirect to the SAML Identity Provider. You can use the *stay* parameter, to prevent that, and execute the redirection manually. We need to use that if a match on the future SAMLResponse ID and the AuthNRequest ID to be sent is required. That AuthNRequest ID must be extracted and stored for future validation, so we can't execute the redirection on the login. Instead, set *stay* to true, then get that ID by
370369
```
371370
auth.getLastRequestId()
372371
```
373-
and later excuting the redirection manually.
372+
and later executing the redirection manually.
374373

375374

376375
#### The SP Endpoints
@@ -441,7 +440,7 @@ if (!errors.isEmpty()) {
441440
}
442441
}
443442
```
444-
The SAML response is processed and then checked that there are no errors. It also verifies that the user is authenticated and stored the userdata in session.
443+
The SAML response is processed and then checked to ensure that there are no errors. It also verifies that the user is authenticated, and then the userdata is stored in the session.
445444
At that point there are 2 possible alternatives:
446445
- If no RelayState is provided, we could show the user data in this view or however we wanted.
447446
- If RelayState is provided, a redirection take place.

0 commit comments

Comments
 (0)