Skip to content

Commit 21bf4a2

Browse files
authored
Merge pull request #25 from CyberSource/latest
Push latest changes up to master
2 parents 9a77d93 + 1024612 commit 21bf4a2

3 files changed

Lines changed: 23 additions & 23 deletions

File tree

README.md

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,41 +1,41 @@
11
# CyberSource Flex Samples
22

3-
This repository provides simple examples demonstrating usage of the CyberSource Flex SDK using either a headless javascript call (jsp-flexjs) or a fully customizable hosted field/microform which is incorporated into your checkout page. For more details on Secure Acceptance Flex visit our Developer Guide at https://developer.cybersource.com/api/developer-guides/dita-flex/SAFlexibleToken.html
3+
This repository provides simple examples demonstrating usage of the CyberSource Flex SDK using either a headless JavaScript call (jsp-flexjs) or a fully customizable hosted field/microform which is incorporated into your checkout page. For more details on Secure Acceptance Flex visit our Developer Guide at https://developer.cybersource.com/api/developer-guides/dita-flex/SAFlexibleToken.html
44

55
## Usage
66

77
1. Clone or download this repository.
8-
2. Update webapp/WEB-INF/credentials.properties with your CAS/Sandbox credentials
9-
3. Run mvn package in the sample you want to try (jsp-microform or jsp-flexjs)
10-
4. Copy the output WAR file to your web server directory
8+
2. Update webapp/WEB-INF/credentials.properties with your [CyberSource sandbox credentials](https://ebc2test.cybersource.com).
9+
3. Run ```mvn package``` in the sample you want to try (jsp-microform or jsp-flexjs).
10+
4. Copy the output WAR file to your web server directory.
1111

1212
## Requirements
13-
* Java 1.8 or later .
14-
* Tomcat web server .
13+
* Java 1.8 or later
14+
* Tomcat web server
1515

16-
**_NOTE: While this sample currently requires Java we are planning to release samples in other languages/stacks over the coming months_**
16+
**_NOTE: While this sample currently requires Java, we are planning to release samples in other languages/stacks over the coming months_**
1717

1818
## API Reference
19-
While these examples use the Javascript libraries which we recommend as the most convenient option you can try out the APIs behind the Javascript SDKs by visiting out API Reference at https://developer.cybersource.com/api/reference/api-reference.html
19+
While these examples use the JavaScript libraries which we recommend as the most convenient option, you can try out the APIs behind the JavaScript SDKs by visiting our API Reference at https://developer.cybersource.com/api/reference/api-reference.html
2020

2121
## Background on PCI-DSS
2222

23-
Storing your customer’s card data can dramatically increase your repeat-custom conversion rate, but can also add additional risk and [PCI DSS](https://www.pcisecuritystandards.org/pci_security/) overhead. You can mitigate these costs by tokenizing card data. CyberSource will store your customer’s card data within secure Visa data centers, replacing it with a token that only you can use.
23+
Storing your customer’s card data can dramatically increase your repeat-customer conversion rate, but can also add additional risk and [PCI DSS](https://www.pcisecuritystandards.org/pci_security/) overhead. You can mitigate these costs by tokenizing card data. CyberSource will store your customer’s card data within secure Visa data centers, replacing it with a token that only you can use.
2424

25-
Secure Acceptance Flexible Token is a secure method for Tokenizing card data, that leaves you in total control of the customer experience. Your customer’s card number is encrypted on their own device, for example inside a browser or native app, and sent directly to CyberSource. This means card data bypasses your systems altogether. This can help you qualify for [SAQ A](https://www.pcisecuritystandards.org/documents/Understanding_SAQs_PCI_DSS_v3.pdf) based PCI DSS assessments for web based integrations, and [SAQ A-EP](https://www.pcisecuritystandards.org/documents/Understanding_SAQs_PCI_DSS_v3.pdf) for native app integrations.
25+
Secure Acceptance Flexible Token is a secure method for Tokenizing card data, that leaves you in total control of the customer experience. Your customer’s card number is encrypted on their own device - for example inside a browser or native app - and sent directly to CyberSource. This means card data bypasses your systems altogether. This can help you qualify for [SAQ A](https://www.pcisecuritystandards.org/documents/Understanding_SAQs_PCI_DSS_v3.pdf) based PCI DSS assessments for web-based integrations, and [SAQ A-EP](https://www.pcisecuritystandards.org/documents/Understanding_SAQs_PCI_DSS_v3.pdf) for native app integrations.
2626

2727
You are in total control of the look and feel, with the ability to seamlessly blend the solution in to your existing checkout flow, on web or in-app.
2828

2929
On-device encryption helps to protect your customers from attacks on network middleware such as app accelerators, DLPs, CDNs, and malicious hotspots.
3030

31-
The token can be used in lieu of actual card data in server-side requests for other CyberSource services, for example to make a payment, using our REST APIs : https://developer.cybersource.com/api/reference/api-reference.html
31+
The token can be used in lieu of actual card data in server-side requests for other CyberSource services, for example to make a payment, using our REST APIs: https://developer.cybersource.com/api/reference/api-reference.html
3232

3333
## Samples
3434

35-
### Javascript (Flex API) Sample
35+
### JavaScript (Flex API) Sample
3636

37-
This sample demonstrates how your checkout form can remain exactly as it is today, the only addition will be a javascript call to tokenize the customers credit card information directly FROM their browser (to CyberSource) replacing that data with a secure PCI-compliant token which you can then post up to your server along with the other non-PCI order data. This provides PCI-DSS SAQ-A(EP) level compliance for your application.
37+
This sample demonstrates how your checkout form can remain exactly as it is today, with the only addition of a JavaScript call to tokenize the customer's credit card information. This happens directly between their browser and CyberSource, replacing the provided data with a secure PCI-compliant token. This can then be sent to your server along with the other non-PCI order data. This can help achieve PCI-DSS SAQ A-EP level compliance for your application.
3838

3939
### Microform Sample
4040

41-
This sample demonstrates how you can replace the sensitive data fields (credit card number) on your checkout form, with a field (Flex Microform) hosted entirely on CyberSource servers. This field will accept and tokenize the customers credit card information directly FROM their browser (to CyberSource), replacing that data with a secure PCI-compliant token which you can then post up to your server along with the other non-PCI order data. This provides PCI-DSS SAQ-A level compliance for your application as even your client-side code does not contain any code to handle the credit card number.
41+
This sample demonstrates how you can replace the sensitive data fields (credit card number) on your checkout form with a field (Flex Microform) hosted entirely on CyberSource servers. This field will accept and tokenize the customer's credit card information directly from their browser on a resource hosted by CyberSource, replacing that data with a secure PCI-compliant token. This can then be sent to your server along with the other non-PCI order data. This can help achieve PCI-DSS SAQ A level compliance for your application as even your client-side code does not contain a mechanism to handle the credit card information.

jsp-flexjs/README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Flex API Sample
22

3-
A simple client-side tokenization example integration using Flex Javascript SDK to access the Flex API. For more details on this see our Developer Guide at https://developer.cybersource.com/api/developer-guides/dita-flex/SAFlexibleToken/FlexAPI.html
3+
A simple client-side tokenization example integration using Flex JavaScript SDK to access the Flex API. For more details on this see our Developer Guide at: https://developer.cybersource.com/api/developer-guides/dita-flex/SAFlexibleToken/FlexAPI.html
44

55
## Prerequisites
66

@@ -11,17 +11,17 @@ A simple client-side tokenization example integration using Flex Javascript SDK
1111

1212
## Setup Instructions
1313

14-
1. Modify `./src/main/webapp/credentials.properties` with the Cybersource REST credentials created through [EBC Portal](https://ebc2.cybersource.com/).
14+
1. Modify `./src/main/webapp/credentials.properties` with the CyberSource REST credentials created through [EBC Portal](https://ebc2test.cybersource.com/).
1515

1616
```
1717
merchantId=YOUR MERCHANT ID
18-
keyId=YOUR KEY ID
18+
keyId=YOUR KEY ID (SHARED SECRET SERIAL NUMBER)
1919
sharedSecret=YOUR SHARED SECRET
2020
```
2121

2222
2. Build and run the application using maven
2323
```bash
24-
mvn package
24+
mvn clean package
2525
```
2626

2727
This will produce a `.war` file that can be deployed to a Tomcat server instance. The deployed application will serve a demonstration card tokenization page on `http://localhost:8080/`. To serve from a different domain, ensure that `targetOrigin` domain is specified when making a call to the `/keys` endpoint. For a detailed example please see [FlexKeyProvider.java](./src/main/java/com/cybersource/example/FlexKeyProvider.java), line 47.

jsp-microform/README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Flex Microform Sample
22

3-
Flex Microform is a CyberSource-hosted HTML/Javascript component that replaces the card number input field on your checkout page and calls the Flex API on your behalf. This simple example integration demonstrates using the Flex Microform SDK to embed this PCI SAQ-A level component in your form. For more details on this see our Developer Guide at https://developer.cybersource.com/api/developer-guides/dita-flex/SAFlexibleToken/FlexMicroform.html
3+
Flex Microform is a CyberSource-hosted HTML/JavaScript component that replaces the card number input field on your checkout page and calls the Flex API on your behalf. This simple example integration demonstrates using the Flex Microform SDK to embed this PCI SAQ A level component in your form. For more details on this see our Developer Guide at: https://developer.cybersource.com/api/developer-guides/dita-flex/SAFlexibleToken/FlexMicroform.html
44

55
## Prerequisites
66

@@ -11,24 +11,24 @@ Flex Microform is a CyberSource-hosted HTML/Javascript component that replaces t
1111

1212
## Setup Instructions
1313

14-
1. Modify `./src/main/webapp/credentials.properties` with the Cybersource REST credentials created through [EBC Portal](https://ebc2.cybersource.com/).
14+
1. Modify `./src/main/webapp/credentials.properties` with the CyberSource REST credentials created through [EBC Portal](https://ebc2test.cybersource.com/).
1515

1616
```
1717
merchantId=YOUR MERCHANT ID
18-
keyId=YOUR KEY ID
18+
keyId=YOUR KEY ID (SHARED SECRET SERIAL NUMBER)
1919
sharedSecret=YOUR SHARED SECRET
2020
```
2121

2222
2. Build and run the application using maven
2323
```bash
24-
mvn clean install
24+
mvn clean package
2525
```
2626

2727
This will produce a `.war` file that can be deployed to a Tomcat server instance. The deployed application will serve a demonstration card tokenization page on `http://localhost:8080/`. To serve from a different domain, ensure that `targetOrigin` domain is specified when making a call to the `/keys` endpoint. For a detailed example please see [FlexKeyProvider.java](./src/main/java/com/cybersource/example/FlexKeyProvider.java), line 47.
2828

2929
## Tips
3030

31-
- If you are having issues, checkout the full [Hosted FLEX documentation](https://developer.cybersource.com/api/developer-guides/dita-flex/SAFlexibleToken/FlexMicroform.html).
31+
- If you are having issues, checkout the full [FLEX Microform documentation](https://developer.cybersource.com/api/developer-guides/dita-flex/SAFlexibleToken/FlexMicroform.html).
3232

3333
- If the application throws `java.security.InvalidKeyException: Illegal key size` you have probably not installed the [JCE unlimited policy files](http://www.oracle.com/technetwork/java/javase/downloads/jce8-download-2133166.html).
3434

0 commit comments

Comments
 (0)