8000 Merge pull request #152 from AuthorizeNet/future · AuthorizeNet/sdk-java@b73c729 · GitHub
[go: up one dir, main page]

Skip to content

Commit b73c729

Browse files
authored
Merge pull request #152 from AuthorizeNet/future
Update to v1.9.9
2 parents 1c4eb3f + e7da3ce commit b73c729

24 files changed

+2588
-47
lines changed

README.md

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,36 @@ To create the javadocs...
114114
### Testing Guide
115115
For additional help in testing your own code, Authorize.Net maintains a [comprehensive testing guide](http://developer.authorize.net/hello_world/testing_guide/) that includes test credit card numbers to use and special triggers to generate certain responses from the sandbox environment.
116116

117+
## Logging Sensitive Data
118+
119+
The Authorize.Net Java SDK uses Log4J framework for logging purposes and it can be enabled by keeping a configuration file `Log4j.properties` in the resources folder of the application. A sample [Log4.properties](https://github.com/AuthorizeNet/sdk-java/blob/master/resources/log4j.properties) file has been provided as a reference.
120+
121+
The possible log levels are `DEBUG, INFO, WARN, ERROR` and `FATAL`. There is a new pattern layout introduced to mask sensitive data while logging and can be used with the application by providing the following configurations in the `Log4j.properties` file:
122+
123+
```
124+
// Default configuration which logs the entries in clear text
125+
126+
log4j.appender.S.layout = org.apache.log4j.PatternLayout
127+
log4j.appender.R.layout = org.apache.log4j.PatternLayout
128+
< 8000 /div>
129+
// Configuration which masks the sensitive data in the log entries
130+
131+
log4j.appender.S.layout = net.authorize.util.SensitiveFilterLayout
132+
log4j.appender.R.layout = net.authorize.util.SensitiveFilterLayout
133+
134+
```
135+
136+
By default the logger comes with two appenders i.e **console** and **file transport**.
137+
138+
The list of sensitive fields which can be masked during logging are:
139+
* Card Number,
140+
* Card Code,
141+
* Expiration Date,
142+
* Name on Account,
143+
* Transaction Key, and
144+
* Account Number.
145+
146+
There is also a list of regular expressions which the sensitive logger uses to mask credit card numbers while logging. Further information on the sensitive data logging and regular expressions can be found at this [location](https://github.com/AuthorizeNet/sdk-java/blob/master/resources/AuthorizedNetSensitiveTagsConfig.json).
117147

118148
## License
119149
This repository is distributed under a proprietary license. See the provided [`LICENSE.txt`](/LICENSE.txt) file.

src/main/java/net/authorize/api/contract/v1/ANetApiRequest.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802
33
// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
44
// Any modifications to this file will be lost upon recompilation of the source schema.
5-
// Generated on: 2018.06.13 at 02:31:45 PM IST
5+
// Generated on: 2018.11.14 at 11:09:15 AM IST
66
//
77

88

@@ -99,6 +99,7 @@
9999
DeleteCustomerShippingAddressRequest.class,
100100
UpdateHeldTransactionRequest.class,
101101
UpdateCustomerProfileRequest.class,
102+
GetCustomerPaymentProfileNonceRequest.class,
102103
CreateCustomerProfileFromTransactionRequest.class
103104
})
104105
public class ANetApiRequest implements java.io.Serializable {

src/main/java/net/authorize/api/contract/v1/ANetApiResponse.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802
33
// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
44
// Any modifications to this file will be lost upon recompilation of the source schema.
5-
// Generated on: 2018.06.13 at 02:31:45 PM IST
5+
// Generated on: 2018.11.14 at 11:09:15 AM IST
66
//
77

88

@@ -45,6 +45,7 @@
4545
"sessionToken"
4646
})
4747
@XmlSeeAlso({
48+
GetCustomerPaymentProfileNonceResponse.class,
4849
UpdateHeldTransactionResponse.class,
4950
ValidateCustomerPaymentProfileResponse.class,
5051
GetUnsettledTransactionListResponse.class,
Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
//
2+
// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802
3+
// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
4+
// Any modifications to this file will be lost upon recompilation of the source schema.
5+
// Generated on: 2018.11.14 at 11:09:15 AM IST
6+
//
7+
8+
9+
package net.authorize.api.contract.v1;
10+
11+
import java.util.ArrayList;
12+
import java.util.List;
13+
import javax.xml.bind.annotation.XmlAccessType;
14+
import javax.xml.bind.annotation.XmlAccessorType;
15+
import javax.xml.bind.annotation.XmlType;
16+
17+
18+
/**
19+
* <p>Java class for ArrayOfContactDetail complex type.
20+
*
21+
* <p>The following schema fragment specifies the expected content contained within this class.
22+
*
23+
* <pre>
24+
* &lt;complexType name="ArrayOfContactDetail">
25+
* &lt;complexContent>
26+
* &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
27+
* &lt;sequence>
28+
* &lt;element name="contactDetail" type="{AnetApi/xml/v1/schema/AnetApiSchema.xsd}ContactDetailType" maxOccurs="unbounded" minOccurs="0"/>
29+
* &lt;/sequence>
30+
* &lt;/restriction>
31+
* &lt;/complexContent>
32+
* &lt;/complexType>
33+
* </pre>
34+
*
35+
*
36+
*/
37+
@XmlAccessorType(XmlAccessType.FIELD)
38+
@XmlType(name = "ArrayOfContactDetail", propOrder = {
39+
"contactDetail"
40+
})
41+
public class ArrayOfContactDetail {
42+
43+
protected List<ContactDetailType> contactDetail;
44+
45+
/**
46+
* Gets the value of the contactDetail property.
47+
*
48+
* <p>
49+
* This accessor method returns a reference to the live list,
50+
* not a snapshot. Therefore any modification you make to the
51+
* returned list will be present inside the JAXB object.
52+
* This is why there is not a <CODE>set</CODE> method for the contactDetail property.
53+
*
54+
* <p>
55+
* For example, to add a new item, do as follows:
56+
* <pre>
57+
* getContactDetail().add(newItem);
58+
* </pre>
59+
*
60+
*
61+
* <p>
62+
* Objects of the following type(s) are allowed in the list
63+
* {@link ContactDetailType }
64+
*
65+
*
66+
*/
67+
public List<ContactDetailType> getContactDetail() {
68+
if (contactDetail == null) {
69+
contactDetail = new ArrayList<ContactDetailType>();
70+
}
71+
return this.contactDetail;
72+
}
73+
74+
}
Lines changed: 139 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,139 @@
1+
//
2+
// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.8-b130911.1802
3+
// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
4+
// Any modifications to this file will be lost upon recompilation of the source schema.
5+
// Generated on: 2018.11.14 at 11:09:15 AM IST
6+
//
7+
8+
9+
package net.authorize.api.contract.v1;
10+
11+
import javax.xml.bind.annotation.XmlAccessType;
12+
import javax.xml.bind.annotation.XmlAccessorType;
13+
import javax.xml.bind.annotation.XmlType;
14+
15+
16+
/**
17+
* <p>Java class for ContactDetailType complex type.
18+
*
19+
* <p>The following schema fragment specifies the expected content contained within this class.
20+
*
21+
* <pre>
22+
* &lt;complexType name="ContactDetailType">
23+
* &lt;complexContent>
24+
* &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
25+
* &lt;sequence>
26+
* &lt;element name="email" minOccurs="0">
27+
* &lt;simpleType>
28+
* &lt;restriction base="{http://www.w3.org/2001/XMLSchema}string">
29+
* &lt;maxLength value="255"/>
30+
* &lt;/restriction>
31+
* &lt;/simpleType>
32+
* &lt;/element>
33+
* &lt;element name="firstName" minOccurs="0">
34+
* &lt;simpleType>
35+
* &lt;restriction base="{http://www.w3.org/2001/XMLSchema}string">
36+
* &lt;maxLength value="50"/>
37+
* &lt;/restriction>
38+
* &lt;/simpleType>
39+
* &lt;/element>
40+
* &lt;element name="lastName" minOccurs="0">
41+
* &lt;simpleType>
42+
* &lt;restriction base="{http://www.w3.org/2001/XMLSchema}string">
43+
* &lt;maxLength value="50"/>
44+
* &lt;/restriction>
45+
* &lt;/simpleType>
46+
* &lt;/element>
47+
* &lt;/sequence>
48+
* &lt;/restriction>
49+
* &lt;/complexContent>
50+
* &lt;/complexType>
51+
* </pre>
52+
*
53+
*
54+
*/
55+
@XmlAccessorType(XmlAccessType.FIELD)
56+
@XmlType(name = "ContactDetailType", propOrder = {
57+
"email",
58< F438 /code>+
"firstName",
59+
"lastName"
60+
})
61+
public class ContactDetailType {
62+
63+
protected String email;
64+
protected String firstName;
65+
protected String lastName;
66+
67+
/**
68+
* Gets the value of the email property.
69+
*
70+
* @return
71+
* possible object is
72+
* {@link String }
73+
*
74+
*/
75+
public String getEmail() {
76+
return email;
77+
}
78+
79+
/**
80+
* Sets the value of the email property.
81+
*
82+
* @param value
83+
* allowed object is
84+
* {@link String }
85+
*
86+
*/
87+
public void setEmail(String value) {
88+
this.email = value;
89+
}
90+
91+
/**
92+
* Gets the value of the firstName property.
93+
*
94+
* @return
95+
* possible object is
96+
* {@link String }
97+
*
98+
*/
99+
public String getFirstName() {
100+
return firstName;
101+
}
102+
103+
/**
104+
* Sets the value of the firstName property.
105+
*
106+
* @param value
107+
* allowed object is
108+
* {@link String }
109+
*
110+
*/
111+
public void setFirstName(String value) {
112+
this.firstName = value;
113+
}
114+
115+
/**
116+
* Gets the value of the lastName property.
117+
*
118+
* @return
119+
* possible object is
120+
* {@link String }
121+
*
122+
*/
123+
public String getLastName() {
124+
return lastName;
125+
}
126+
127+
/**
128+
* Sets the value of the lastName property.
129+
*
130+
* @param value
131+
* allowed object is
132+
* {@link String }
133+
*
134+
*/
135+
public void setLastName(String value) {
136+
this.lastName = value;
137+
}
138+
139+
}

0 commit comments

Comments
 (0)
0