# How to ensure flow is created by insider

**URL:** https://discourse.nodered.org/t/how-to-ensure-flow-is-created-by-insider/80360
**Category:** General
**Created:** [7 August 2023 02:10 UTC](https://discourse.nodered.org/t/how-to-ensure-flow-is-created-by-insider/80360 "2023-08-07T02:10:31Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![HenryTrang](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/henrytrang/32/81582_2.png) [@HenryTrang](https://discourse.nodered.org/u/HenryTrang)
#### Post date: [7 August 2023 02:10 UTC](https://discourse.nodered.org/t/how-to-ensure-flow-is-created-by-insider/80360/1 "2023-08-07T02:10:31Z")

</div>

Dear Sir

May i ask how to listen deploy button. how to hold on and move on deploy the flow. as before deploy i need to verify if this flow is created or edited by insider.

Best regard!  
Henry

---

<div class="post-metadata">

### Author: ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)
#### Post date: [7 August 2023 08:23 UTC](https://discourse.nodered.org/t/how-to-ensure-flow-is-created-by-insider/80360/2 "2023-08-07T08:23:05Z")

</div>

While Node-RED does issue an event when deploy happens - I think there may be a pre-deploy event as well, can't quite remember but if there is, that would let you prevent a deploy from occurring - it isn't really what Node-RED is set up for I don't believe. Anyone with rights to change the flows via the Editor interface is assumed to be trusted to change the flow. There isn't even an audit that would record a specific Node-RED user (as opposed to the OS user that runs Node-RED) has made a change, something that would be a bare minimum for a secure system where multiple users are allowed to make changes.

I think that you would probably need to embed Node-RED in your own service (which is easy enough) in order to achieve anything more.

---

<div class="post-metadata">

### Author: ![HenryTrang](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/henrytrang/32/81582_2.png) [@HenryTrang](https://discourse.nodered.org/u/HenryTrang)
#### Post date: [7 August 2023 08:31 UTC](https://discourse.nodered.org/t/how-to-ensure-flow-is-created-by-insider/80360/3 "2023-08-07T08:31:50Z")

</div>

![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/9/b/9bcda3bd38028b2def79d6def940d0fe4e727228.png)  
i found save function, in red.js. and i try to add some log in the function, but no print. client require to verify user it is not my call. thanks for reply

---

<div class="post-metadata">

### Author: ![HenryTrang](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/henrytrang/32/81582_2.png) [@HenryTrang](https://discourse.nodered.org/u/HenryTrang)
#### Post date: [8 August 2023 01:40 UTC](https://discourse.nodered.org/t/how-to-ensure-flow-is-created-by-insider/80360/4 "2023-08-08T01:40:57Z")

</div>

hi all thanks for concern. i figure out how. it is in red.min.js. find out this file and modify save method, it work.

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)
#### Post date: [22 August 2023 01:41 UTC](https://discourse.nodered.org/t/how-to-ensure-flow-is-created-by-insider/80360/5 "2023-08-22T01:41:54Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
