37 lines
795 B
Plaintext
37 lines
795 B
Plaintext
include::../description.adoc[]
|
|
|
|
include::../ask-yourself.adoc[]
|
|
|
|
include::../recommended.adoc[]
|
|
|
|
== Sensitive Code Example
|
|
|
|
----
|
|
public class MyClient {
|
|
public void SendRequest(){
|
|
HttpRequest req = new HttpRequest();
|
|
req.setEndpoint('http://example.com'); // Sensitive
|
|
// ...
|
|
}
|
|
}
|
|
----
|
|
|
|
== Compliant Solution
|
|
|
|
----
|
|
public class MyClient {
|
|
public void SendRequest(){
|
|
HttpRequest req = new HttpRequest();
|
|
req.setEndpoint('https://example.com'); // Compliant
|
|
// ...
|
|
}
|
|
}
|
|
----
|
|
|
|
include::../exceptions.adoc[]
|
|
|
|
== See
|
|
|
|
* https://www.owasp.org/index.php/Top_10-2017_A3-Sensitive_Data_Exposure[OWASP Top 10 2017 Category A3] - Sensitive Data Exposure
|
|
* https://cwe.mitre.org/data/definitions/200.html[MITRE, CWE-200] - Information Exposure
|