|
1 | 1 | { |
2 | | - "name": "My workflow", |
| 2 | + "name": "Simple Workflow", |
3 | 3 | "nodes": [ |
4 | 4 | { |
5 | 5 | "parameters": { |
6 | | - "loginURL": "http://localhost:8080/login", |
7 | | - "afterLoginURL": "http://localhost:8080/protected", |
8 | | - "logoutURL": "http://localhost:8080/login", |
| 6 | + "authURL": "http://localhost:8080/_auth", |
| 7 | + "loginRedirectURL": "http://localhost:8080", |
| 8 | + "logoutRedirectURL": "http://localhost:8080/signed-out", |
9 | 9 | "enableHTTP": true |
10 | 10 | }, |
11 | 11 | "type": "CUSTOM.httpForwardAuthTrigger", |
12 | 12 | "typeVersion": 1, |
13 | 13 | "position": [ |
14 | | - -360, |
15 | | - 20 |
| 14 | + 0, |
| 15 | + 0 |
16 | 16 | ], |
17 | | - "id": "de7c6620-31c8-4701-b870-dc6825487f35", |
| 17 | + "id": "69c907ff-c556-458f-89e4-cd68c6d2bfa8", |
18 | 18 | "name": "HTTP Forward Auth Trigger", |
19 | 19 | "webhookId": "aa1e42ef-7492-4235-9f22-e3c007358d15" |
20 | 20 | }, |
|
26 | 26 | "type": "CUSTOM.httpForwardAuth", |
27 | 27 | "typeVersion": 1, |
28 | 28 | "position": [ |
29 | | - 920, |
30 | | - 20 |
| 29 | + 1280, |
| 30 | + 0 |
31 | 31 | ], |
32 | | - "id": "3368c9bf-3dab-4bd8-9d7f-d5f1abe7610e", |
| 32 | + "id": "5c5bd1f9-68ca-45cc-9c3d-169bd5fed21b", |
33 | 33 | "name": "HTTP Forward Auth" |
34 | 34 | }, |
35 | 35 | { |
36 | 36 | "parameters": { |
37 | | - "jsCode": "const db = {\n \"test1@example.com\": \"g9QaXzlc34l4dEw1c6HOHcBrVP6SFswS|BIVTqZnqdUbrS8JiuugWKl1Ch0NaADWaFcIiDpc4Tac=\",\n \"[email protected]\": \"eSOLsrieYnZ96jNCXfalGF15sJxdluc2|cXFQ/PT1VNb/CRM6SA/d+ADQlS1hwDgtg/tuWipDbbo=\",\n \"[email protected]\": \"kos8kWXOH7Nr7v72q3kXUzxUwxmKx2uo|Rj3A2BLRCtpKFVjxb6IxuSgLIigbt3wlKazsFGmO5ic=\"\n};\n\nconst userRaw = db[$input.first().json.user];\n\nif(userRaw) {\n const [salt, hash] = userRaw.split(\"|\");\n return { salt, hash }\n}\n\nreturn { salt: \"\", hash: \"\" }" |
| 37 | + "jsCode": "const db = {\n \"admin@example.com\": \"g9QaXzlc34l4dEw1c6HOHcBrVP6SFswS|Q5LA5FkQb1HpuRz0ppjnQPm13kpyjy7PdgRKIb+VRPI=\" \n};\n\nconst userRaw = db[$input.first().json.user];\n\nif(userRaw) {\n const [salt, hash] = userRaw.split(\"|\");\n return { salt, hash }\n}\n\nreturn { salt: \"\", hash: \"\" }" |
38 | 38 | }, |
39 | 39 | "type": "n8n-nodes-base.code", |
40 | 40 | "typeVersion": 2, |
41 | 41 | "position": [ |
42 | | - -60, |
43 | | - 20 |
| 42 | + 300, |
| 43 | + 0 |
44 | 44 | ], |
45 | | - "id": "87fa2215-c45c-4950-ae1a-97216eb30e9f", |
| 45 | + "id": "1dfbe11d-385d-4eea-9a0f-ebe3425fa6c3", |
46 | 46 | "name": "Get Data From DB" |
47 | 47 | }, |
48 | 48 | { |
|
55 | 55 | "type": "n8n-nodes-base.crypto", |
56 | 56 | "typeVersion": 1, |
57 | 57 | "position": [ |
58 | | - 280, |
59 | | - 20 |
| 58 | + 640, |
| 59 | + 0 |
60 | 60 | ], |
61 | | - "id": "4ac9ba87-0753-4ad9-af56-acbfdb8ecabf", |
| 61 | + "id": "ba283396-0f28-43d7-b460-df3291d5d867", |
62 | 62 | "name": "Hash Password" |
63 | 63 | }, |
64 | 64 | { |
|
68 | 68 | "type": "n8n-nodes-base.code", |
69 | 69 | "typeVersion": 2, |
70 | 70 | "position": [ |
71 | | - 600, |
72 | | - 20 |
| 71 | + 960, |
| 72 | + 0 |
73 | 73 | ], |
74 | | - "id": "c3c058a6-eb0d-418e-81f2-9cf142360e34", |
| 74 | + "id": "6810f87d-f5b4-40ec-872e-9108167f2dcd", |
75 | 75 | "name": "Verify Password" |
| 76 | + }, |
| 77 | + { |
| 78 | + "parameters": { |
| 79 | + "content": "## Access Info\nuser: [email protected]\npassword: password" |
| 80 | + }, |
| 81 | + "type": "n8n-nodes-base.stickyNote", |
| 82 | + "position": [ |
| 83 | + 240, |
| 84 | + -180 |
| 85 | + ], |
| 86 | + "typeVersion": 1, |
| 87 | + "id": "ad36117b-104b-4f40-9240-c83f909a8085", |
| 88 | + "name": "Sticky Note" |
76 | 89 | } |
77 | 90 | ], |
78 | 91 | "pinData": {}, |
|
124 | 137 | }, |
125 | 138 | "active": true, |
126 | 139 | "settings": { |
127 | | - "executionOrder": "v1", |
128 | | - "saveDataErrorExecution": "none", |
129 | | - "saveDataSuccessExecution": "none", |
130 | | - "saveExecutionProgress": false, |
131 | | - "saveManualExecutions": false, |
132 | | - "callerPolicy": "workflowsFromSameOwner", |
133 | | - "executionTimeout": -1 |
| 140 | + "executionOrder": "v1" |
134 | 141 | }, |
135 | | - "versionId": "9b417754-d9d0-4377-8863-e604f59f97f1", |
| 142 | + "versionId": "86c9094b-196d-49e0-be04-60f19353569a", |
136 | 143 | "meta": { |
137 | | - "templateCredsSetupCompleted": true, |
138 | | - "instanceId": "505a91c807f383cfa51524b51406539ed2a13b65faca94769375174ae416a1e6" |
| 144 | + "templateCredsSetupCompleted": true |
139 | 145 | }, |
140 | | - "id": "4hi91Jg1ssmzLJwF", |
| 146 | + "id": "DRLuFvbB6tyPxGpi", |
141 | 147 | "tags": [] |
142 | 148 | } |
0 commit comments