cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
nauman77us
Frequent Visitor

Custom API to authenticate with encrypted password

how we can encrypt password. I want to call API to authenticate which takes username and password but i want to pass encrypted password. How we can do?

I have a .net api. I can even change .net api code. But i want to know how can i pass encrypted password to my custom API. 

I have create a flow and calling through Power apps. In that flow i am using custom API to pass the username and password for authentication.

 

1 ACCEPTED SOLUTION

Accepted Solutions
v-xida-msft
Community Support
Community Support

Hi @nauman77us ,

Could you please share a bit more about your scenario?

Do you want to encrypt the received password within your Power Automate flow?

 

If you want to encrypt the received password within your Power Automate flow, I afraid that there is no way to achieve your needs. Currently, the encrypt function/expression is not supported in Power Apps and Power Automate flow.

 

If you would like this feature to be added in PowerApps, please consider submit an idea to Power Apps Ideas Forum:

https://powerusers.microsoft.com/t5/Power-Apps-Ideas/idb-p/PowerAppsIdeas

 

As an alternative solution, you could consider set up a encrypt/decrypt API using .net code. Then within your Power Apps or Power Automate, you could set up a custom connector based on this encrypt/decrypt API.

Then within your Power Automate flow, you could add a connection to the encrypt action of this custom connector (before the "HTTP" action), use it to encrypt the passed password value. Then within the "HTTP" action, include the encrypted password value returned from the encrypt action of this custom connector.

 

Within your custom API (authenticate username and password), you need to the invoke the decrypt function of above encrypt/decrypt API to decrypt the received encrypted password. Then you could complete your authentication process.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
v-xida-msft
Community Support
Community Support

Hi @nauman77us ,

Could you please share a bit more about your scenario?

Do you want to encrypt the received password within your Power Automate flow?

 

If you want to encrypt the received password within your Power Automate flow, I afraid that there is no way to achieve your needs. Currently, the encrypt function/expression is not supported in Power Apps and Power Automate flow.

 

If you would like this feature to be added in PowerApps, please consider submit an idea to Power Apps Ideas Forum:

https://powerusers.microsoft.com/t5/Power-Apps-Ideas/idb-p/PowerAppsIdeas

 

As an alternative solution, you could consider set up a encrypt/decrypt API using .net code. Then within your Power Apps or Power Automate, you could set up a custom connector based on this encrypt/decrypt API.

Then within your Power Automate flow, you could add a connection to the encrypt action of this custom connector (before the "HTTP" action), use it to encrypt the passed password value. Then within the "HTTP" action, include the encrypted password value returned from the encrypt action of this custom connector.

 

Within your custom API (authenticate username and password), you need to the invoke the decrypt function of above encrypt/decrypt API to decrypt the received encrypted password. Then you could complete your authentication process.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

You are correct, I would like to use encrypted password to use in the power automate flow. because when i see all the runs it was succeeded but plain text password was displaying in the flow.

 

To prevent this now i am using a custom connector to authenticate. Rest of the things i am using in the power automate flow.  

 

Anyhow thanks for your alternate solution which is good. But i will suggest there should be encrypt and decrypt functions in the power apps.

 

 

Hi @nauman77us ,

Yeah, thanks for your feedback. You could consider submit an idea in PowerApps Ideas Forum, if this feature is added in PowerApps, I would let you know here.

 

You could consider try the alternative solution I provided, if it could help in your scenario, please consider go ahead to click "Accept as Solution" to identify this reply as solution.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Top Kudoed Authors
Users online (1,996)