MCPcopy Index your code
hub / github.com/FlowiseAI/Flowise / maskUrlPassword

Function maskUrlPassword

packages/server/src/utils/index.ts:1773–1782  ·  view source on GitHub ↗
(value: string)

Source from the content-addressed store, hash-verified

1771 * @returns {ICredentialDataDecrypted}
1772 */
1773const maskUrlPassword = (value: string): string | null => {
1774 try {
1775 const url = new URL(value)
1776 if (!url.password) return null
1777 url.password = 'FLOWISE_MASKED'
1778 return url.toString().replace('FLOWISE_MASKED', '\u2022\u2022\u2022\u2022\u2022\u2022')
1779 } catch {
1780 return null
1781 }
1782}
1783
1784export const redactCredentialWithPasswordType = (
1785 componentCredentialName: string,

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected