From 2863920aa4e815cc29c292a5aa9564c59e52d483 Mon Sep 17 00:00:00 2001 From: "Prerna Atwal (patwal)" Date: Fri, 29 Mar 2024 00:32:17 -0700 Subject: [PATCH 1/2] Changes for adding proxy parameters to wordpress custom platform script --- SampleScripts/HTTP/WordPressHttp.json | 43 ++++++++++++++++++++++----- 1 file changed, 36 insertions(+), 7 deletions(-) diff --git a/SampleScripts/HTTP/WordPressHttp.json b/SampleScripts/HTTP/WordPressHttp.json index 20313c1..acd108a 100644 --- a/SampleScripts/HTTP/WordPressHttp.json +++ b/SampleScripts/HTTP/WordPressHttp.json @@ -14,7 +14,11 @@ { "UseSsl": { "Type": "boolean", "Required": false, "DefaultValue": true } }, { "SkipServerCertValidation": { "Type": "boolean", "Required": false, "DefaultValue": true } }, { "Address": { "Type": "String", "Required": true } }, - { "APIURL": { "Type": "String", "Required": true } } + { "APIURL": { "Type": "String", "Required": true } }, + { "ProxyIp": { "Type": "String", "Required": false } }, + { "ProxyPort": { "Type": "String", "Required": false } }, + { "ProxyUser": { "Type": "String", "Required": false } }, + { "ProxyPassword": { "Type": "String", "Required": false } } ], "Do": [ { "Condition": { @@ -42,7 +46,12 @@ "IgnoreServerCertAuthentication": "%{SkipServerCertValidation}%", "Content": { "ContentType": "application/json" - } + }, + "ProxyIp": "%{ProxyIp}%", + "ProxyPort": "%{ProxyPort}%", + "ProxyUser": "%{ProxyUser}%", + "ProxyPassword": "%{ProxyPassword}%" + } }, { "Function": { "Name": "HandleResponse", @@ -58,7 +67,11 @@ { "UseSsl": { "Type": "boolean", "Required": false, "DefaultValue": true } }, { "SkipServerCertValidation": { "Type": "boolean", "Required": false, "DefaultValue": true } }, { "Address": { "Type": "String", "Required": true } }, - { "APIURL": { "Type": "String", "Required": true } } + { "APIURL": { "Type": "String", "Required": true } }, + { "ProxyIp": { "Type": "String", "Required": false } }, + { "ProxyPort": { "Type": "String", "Required": false } }, + { "ProxyUser": { "Type": "String", "Required": false } }, + { "ProxyPassword": { "Type": "String", "Required": false } } ], "Do": [ { "Condition": { @@ -86,7 +99,11 @@ "IgnoreServerCertAuthentication": "%{SkipServerCertValidation}%", "Content": { "ContentType": "application/json" - } + }, + "ProxyIp": "%{ProxyIp}%", + "ProxyPort": "%{ProxyPort}%", + "ProxyUser": "%{ProxyUser}%", + "ProxyPassword": "%{ProxyPassword}%" } }, { @@ -108,7 +125,11 @@ { "UseSsl": { "Type": "boolean", "Required": false, "DefaultValue": true } }, { "SkipServerCertValidation": { "Type": "boolean", "Required": false, "DefaultValue": true } }, { "Address": { "Type": "String", "Required": true } }, - { "APIURL": { "Type": "String", "Required": true } } + { "APIURL": { "Type": "String", "Required": true } }, + { "ProxyIp": { "Type": "String", "Required": false } }, + { "ProxyPort": { "Type": "String", "Required": false } }, + { "ProxyUser": { "Type": "String", "Required": false } }, + { "ProxyPassword": { "Type": "String", "Required": false } } ], "Do": [ { "Condition": { @@ -137,7 +158,11 @@ "IgnoreServerCertAuthentication": "%SkipServerCertValidation%", "Content": { "ContentType": "application/json" - } + }, + "ProxyIp": "%{ProxyIp}%", + "ProxyPort": "%{ProxyPort}%", + "ProxyUser": "%{ProxyUser}%", + "ProxyPassword": "%{ProxyPassword}%" } }, { "SetItem": { "Name": "ParsedUsers", "Value": "" } }, @@ -162,7 +187,11 @@ "Content": { "ContentObjectName": "ChangePassJson", "ContentType": "application/json" - } + }, + "ProxyIp": "%{ProxyIp}%", + "ProxyPort": "%{ProxyPort}%", + "ProxyUser": "%{ProxyUser}%", + "ProxyPassword": "%{ProxyPassword}%" } }, { "Switch": { From 3d8287cc7fc0d6b8d74a283a36e595a43362893e Mon Sep 17 00:00:00 2001 From: "Prerna Atwal (patwal)" Date: Fri, 29 Mar 2024 08:06:35 -0700 Subject: [PATCH 2/2] Updating proxy password type to secret --- SampleScripts/HTTP/WordPressHttp.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/SampleScripts/HTTP/WordPressHttp.json b/SampleScripts/HTTP/WordPressHttp.json index acd108a..75fef28 100644 --- a/SampleScripts/HTTP/WordPressHttp.json +++ b/SampleScripts/HTTP/WordPressHttp.json @@ -18,7 +18,7 @@ { "ProxyIp": { "Type": "String", "Required": false } }, { "ProxyPort": { "Type": "String", "Required": false } }, { "ProxyUser": { "Type": "String", "Required": false } }, - { "ProxyPassword": { "Type": "String", "Required": false } } + { "ProxyPassword": { "Type": "Secret", "Required": false } } ], "Do": [ { "Condition": { @@ -71,7 +71,7 @@ { "ProxyIp": { "Type": "String", "Required": false } }, { "ProxyPort": { "Type": "String", "Required": false } }, { "ProxyUser": { "Type": "String", "Required": false } }, - { "ProxyPassword": { "Type": "String", "Required": false } } + { "ProxyPassword": { "Type": "Secret", "Required": false } } ], "Do": [ { "Condition": { @@ -129,7 +129,7 @@ { "ProxyIp": { "Type": "String", "Required": false } }, { "ProxyPort": { "Type": "String", "Required": false } }, { "ProxyUser": { "Type": "String", "Required": false } }, - { "ProxyPassword": { "Type": "String", "Required": false } } + { "ProxyPassword": { "Type": "Secret", "Required": false } } ], "Do": [ { "Condition": {