Add more security samples (#3344)

* add line break test to petstore-security-test.yaml

* add objc/swift security testing

* add go,scala,qt5cpp for security test

* add security test for typescript

* fix go security issue, fix consumes,produces line break
This commit is contained in:
wing328
2016-07-12 19:51:28 +08:00
committed by GitHub
parent d4951bbf3c
commit 394840e352
146 changed files with 9480 additions and 124 deletions

View File

@@ -1,16 +1,16 @@
# Swagger\Client\FakeApi
All URIs are relative to *https://petstore.swagger.io */ ' " =end/v2 */ ' " =end*
All URIs are relative to *https://petstore.swagger.io *_/ ' \" =end \\r\\n \\n \\r/v2 *_/ ' \" =end \\r\\n \\n \\r*
Method | HTTP request | Description
------------- | ------------- | -------------
[**testCodeInjectEnd**](FakeApi.md#testCodeInjectEnd) | **PUT** /fake | To test code injection */ ' \" =end
[**testCodeInjectEndRnNR**](FakeApi.md#testCodeInjectEndRnNR) | **PUT** /fake | To test code injection *_/ ' \" =end \\r\\n \\n \\r
# **testCodeInjectEnd**
> testCodeInjectEnd($test_code_inject____end)
# **testCodeInjectEndRnNR**
> testCodeInjectEndRnNR($test_code_inject____end_rn_n_r)
To test code injection */ ' \" =end
To test code injection *_/ ' \" =end \\r\\n \\n \\r
### Example
```php
@@ -18,12 +18,12 @@ To test code injection */ ' \" =end
require_once(__DIR__ . '/vendor/autoload.php');
$api_instance = new Swagger\Client\Api\FakeApi();
$test_code_inject____end = "test_code_inject____end_example"; // string | To test code injection */ ' \" =end
$test_code_inject____end_rn_n_r = "test_code_inject____end_rn_n_r_example"; // string | To test code injection *_/ ' \" =end \\r\\n \\n \\r
try {
$api_instance->testCodeInjectEnd($test_code_inject____end);
$api_instance->testCodeInjectEndRnNR($test_code_inject____end_rn_n_r);
} catch (Exception $e) {
echo 'Exception when calling FakeApi->testCodeInjectEnd: ', $e->getMessage(), PHP_EOL;
echo 'Exception when calling FakeApi->testCodeInjectEndRnNR: ', $e->getMessage(), PHP_EOL;
}
?>
```
@@ -32,7 +32,7 @@ try {
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**test_code_inject____end** | **string**| To test code injection */ ' \" =end | [optional]
**test_code_inject____end_rn_n_r** | **string**| To test code injection *_/ ' \" =end \\r\\n \\n \\r | [optional]
### Return type
@@ -44,8 +44,8 @@ No authorization required
### HTTP request headers
- **Content-Type**: application/json, */ ' " =end
- **Accept**: application/json, */ ' " =end
- **Content-Type**: application/json, *_/ \" =end
- **Accept**: application/json, *_/ \" =end
[[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md)

View File

@@ -3,7 +3,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**return** | **int** | property description */ ' \" =end | [optional]
**return** | **int** | property description *_/ ' \" =end \\r\\n \\n \\r | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)