Commit graph

357 commits

Author SHA1 Message Date
abhishek9686
dcb0953d0a remove debug logs 2025-12-03 22:25:02 +04:00
abhishek9686
3d6a026355 fix user sync by groups in azure 2025-12-03 22:23:22 +04:00
abhishek9686
c6792ba4f2 add safe nil check for legacy acls 2025-12-02 18:10:44 +04:00
abhishek9686
3c4cb08692 remove netmaker ip check for nameserver 2025-11-25 15:55:00 +04:00
Vishal Dalwadi
76f2e3a5cd
Release v1.2.0 Fixes (#3728)
* feat(go): add user group as source to default network user acl;

* feat(go): handle "all_networks" network id when removing and cleaning up groups;

* feat(go): handle "all_networks" network id when updating groups;
2025-11-20 09:18:57 +04:00
abhishek9686
e4ab40dee6 remove unreachable code 2025-11-07 12:14:00 +04:00
abhishek9686
1944a9a8b2 disable failover field 2025-11-07 11:52:43 +04:00
Abhishek K
c643a50b67
NM-159: simplify auto assign gw logic (#3719)
* force update host dns field if node is acting as inet gw

* add old acl support checks

* move auto relay migration to pro pkg

* add check to avoid unsetting relayed node

* simplify auto assign gw logic

* send auto assign update on un relay

* set checking time to latest on updates

* fix HA auto Relay logic

* add relay node metrics to peer signal

* move auto relay peer check

* publish host peer update

* check and unset unrelayed auto peers

* use relay node mutex to avoid rac condition

* reset autorelayed peers on auto assign gw
2025-11-06 14:54:09 +04:00
Vishal Dalwadi
fc20b38851
Merge pull request #3718 from gravitl/fix/v1.2.0
Fixes v1.2.0
2025-11-06 13:55:52 +04:00
Vishal Dalwadi
b1e4d1158b
Release Fixes: v1.2.0 (#3713)
* feat(go): allow put and post requests to self;

* feat(go): add old objects to delete events;

* feat(go): add search domains to UserRemoteGws;
2025-11-04 11:46:16 +04:00
Vishal Dalwadi
94770a911d
Merge pull request #3707 from gravitl/NM-158
NM-158: Search Domain Support
2025-11-03 10:54:28 +04:00
Abhishek K
2ab1994886
Merge pull request #3709 from gravitl/master
Master
2025-10-31 15:04:49 +04:00
Abhishek K
74fef9fbc6
NM-122: Auto Relay, auto assignment of Gw (#3697)
* add auto realy handlers and logic funcs

* add pro func connectors

* Add auto relayed peer ips on peer update, set auto relay on gw creation

* add network id to signal, add autorelay nodes to peerudpate

* add autorelay peer update logic

* add nodes to peer update

* revert node model change

* reset auto relayed peers on the relay node on reset, add auto relay nodes to pull

* add logic api to update auto relay node

* add autoassigngw field to node, add logic to swith relay node in relayme udpate api

* add gw nodes to pull

* intilaise gw map

* HA relay functionality

* add autoassign gw option to enrollment key

* publish intant action to auto assign gw

* fix static checks

* unset relay if auto assign removed

* add host node model to auto relay info

* add host node model to auto relay info

* only use hostNode model for gws info

* handle autoassigned gw peer in the update

* handle autoassigned gw peer in the update

* handle peer updates for autoassigned gw peer

* unset auto assigned peer if relayed or failedovered
2025-10-28 09:53:31 +04:00
Abhishek K
c5b48db2a1
NM-125: Egress HA by Latency, Allow Tags to be selected as routing peers (#3698)
* enable egress routing peers with tags

* remove tag from egress when deleted

* fix egress tag functionality

* filter duplicate egress ips

* set default stun server if unset

* add version to status api

* sync deleted node udpate host deletion
2025-10-25 23:49:21 +04:00
Vishal Dalwadi
5448de6036
Allow Netmaker IPs for Nameservers (#3695)
* feat(go): allow netmaker nameserver ip;

* feat(go): filter out node's ips from nameservers;

* feat(go): update nameservers on node deletion;

* address nil checks

* address nil checks

---------

Co-authored-by: abhishek9686 <abhi281342@gmail.com>
2025-10-24 10:19:23 +04:00
Vishal Dalwadi
c4313a4b77
feat(go): add auditor role; (#3684) 2025-10-24 09:56:40 +04:00
Vishal Dalwadi
71fa5013d0
NM-145: Cost Per Network (#3685)
* feat(go): report per network usage as well;

* feat(go): move usage model and logic out of ee;
2025-10-24 09:53:33 +04:00
Vishal Dalwadi
69815449bd
NM-120: Netmaker Desktop DNS Improvements (#3690)
* feat(go): return extclient on create;

* feat(go): return success on delete;

* feat(go): set manage dns on user remote gw;
2025-10-24 09:46:01 +04:00
Abhishek K
54925a3ec9
fix platform user node status, add api for unassigned network user api (#3687) 2025-10-09 09:09:31 +04:00
Abhishek K
8e16c9f07a
IDP Group Filtering Update (#3656)
* fix(go): prevent creating network with fully-masked cidr;

* fix(go): filter out static non-user nodes;

* fix(go): prevent creation of networks with only broadcast and network ip;

* fix(go): cleanup user and groups resources on idp sync;

* fix(go): add "$filter" only once;

* fix(go): add "$filter" only once;

* fix(go): add "$filter" only once;

* fix(go): escape "$filter";

* feat(go): assign synced group global user role id;

---------

Co-authored-by: VishalDalwadi <dalwadivishal26@gmail.com>
Co-authored-by: Vishal Dalwadi <51291657+VishalDalwadi@users.noreply.github.com>
2025-09-18 22:58:30 +05:30
Abhishek K
cba62bfb83
Revert "Allows filters to be updated (#3650)" (#3655)
This reverts commit d90994ccab.
2025-09-18 22:39:36 +05:30
Vishal Dalwadi
d90994ccab
Allows filters to be updated (#3650)
* fix(go): prevent creating network with fully-masked cidr;

* fix(go): filter out static non-user nodes;

* fix(go): prevent creation of networks with only broadcast and network ip;

* fix(go): cleanup user and groups resources on idp sync;

* fix(go): add "$filter" only once;

* fix(go): add "$filter" only once;

* fix(go): add "$filter" only once;

* fix(go): escape "$filter";

* feat(go): assign synced group global user role id;
2025-09-18 22:37:22 +05:30
Abhishek K
aa913d6870
NM-116: Acl Fixes (#3652)
* handle all resources tag on gw

* add egress domain ranges to node acls

* simplify extclient egress alloweips, handle nil acl rule

* fix static node status check for gw acls

* skip ns ip if contains network cidr

* skip ns ip if contains network cidr

* skip ns ip if contains network cidr
2025-09-18 22:27:49 +05:30
Vishal Dalwadi
68707f61f9
Release v1.1.0 Fixes (#3649)
* fix(go): prevent creating network with fully-masked cidr;

* fix(go): filter out static non-user nodes;

* fix(go): prevent creation of networks with only broadcast and network ip;
2025-09-13 13:44:46 +05:30
Vishal Dalwadi
924fcf95bf
Okta IDP Integration (#3648)
* fix(go): handle pagination correctly;

* fix(go): handle api rate limits;
2025-09-13 13:43:30 +05:30
Abhishek K
9e0196126f
NM-79: Domain Based Egress Routing (#3607)
* add support for egress domain routing

* add domain info to egress range

* fix egress domain update

* send peer update domain resolution update

* add egress domain update in the peer update

* use range field for domain check

* add egress domain to host pull

* add egress domain model to egress host update

* add egress domain model to egress host update

* update egress domain model on acls

* add check of range if domain is set

* sync egress domains to dns system

* add egress domain to match domain list, fix egress nat rule for domains

* fix all rsrcs comms

* fix static checks

* fix egress acls on CE

* check for all resources access on a node

* simplify egress acl rules

* merged ce and pro acl rule func

* fix uni direction acl rule for static nodes

* allow relayed nodes traffic

* resolve merge conflicts

* remove anywhere dst rule on user node acls

* fix: broadcast  user groups update for acl changes

* add egress domain ans routes to nodes

* add egress ranges to DST

* add all egress ranges for all resources

* fix DNS routing acls rules
2025-09-11 15:24:17 +05:30
Vishal Dalwadi
57bf34da16
Release v1.1.0 Fixes (#3644)
* fix(go): check for all networks access;

* fix(go): skip group on error;

* fix(go): stabilize get user remote access gw;

* fix(go): use existing extclient sort function;

---------

Co-authored-by: Abhishek K <abhi281342@gmail.com>
2025-09-11 13:49:13 +05:30
Abhishek K
64c6472b42
NM-103: User Acls fixes (#3638)
* fix all rsrcs comms

* fix static checks

* fix egress acls on CE

* check for all resources access on a node

* simplify egress acl rules

* merged ce and pro acl rule func

* fix uni direction acl rule for static nodes

* allow relayed nodes traffic

* remove anywhere dst rule on user node acls

* fix: broadcast  user groups update for acl changes

* add egress ranges to DST

* add all egress ranges for all resources
2025-09-10 12:59:54 +05:30
Abhishek K
dd2aece0de
NM-103: fix all rsrcs comms (#3631)
* fix all rsrcs comms

* fix static checks

* fix egress acls on CE

* check for all resources access on a node

* simplify egress acl rules

* merged ce and pro acl rule func

* fix uni direction acl rule for static nodes

* allow relayed nodes traffic
2025-09-08 07:37:12 +05:30
abhishek9686
53c0b256ae resolve merge conflicts 2025-08-29 12:17:13 +05:30
abhishek9686
b10ce2da14 fix merger errors 2025-08-29 11:48:52 +05:30
abhishek9686
fda691836e fix static check 2025-08-29 11:41:43 +05:30
abhishek9686
7688bc3ebc resolve merge conflicts 2025-08-29 11:37:27 +05:30
Vishal Dalwadi
ec6e6c393a
Prevent removing idp integration when oauth user is superadmin (#3589)
* feat(go): prevent removing idp integration when oauth user is superadmin.

* feat(go): add suggestion for user;

* feat(go): remove usages of boolean fields on user;

* feat(go): set boolean fields correctly, but don't use;

* fix(go): static issues;

* feat(go): add suggestion for user;
2025-08-25 10:28:53 +05:30
Abhishek K
c3498004c1
NM-82: auto create new group network policies (#3610)
* check for all network user groups on gateways selection

* check network admin policy for admins and superadmins

* auto create default group gateways policies

* publish peer update on user group updates

* update name for default group policy
2025-08-25 10:28:24 +05:30
Vishal Dalwadi
2d305e67a4
NM-86: Cleanup User Configs (#3603)
* feat(go): cleanup user extclients;

1. On disabling a user, remove all their extclients.
2. Add comments and rename variables to clarify the user group extclient cleanup function.

* feat(go): add checks for disable and enable user api;

* feat(go): refactor extclient cleanup on group network roles changes;

* feat(go): delete extclient on user group membership changes;
2025-08-25 10:24:15 +05:30
Abhishek K
b1f0843d27
NM-76: add network user api (#3605)
* add network user api

* add remove network user api
2025-08-25 10:21:52 +05:30
Vishal Dalwadi
85e4877803
Merge pull request #3576 from gravitl/NM-38
NM-38: User Config Fixes
2025-08-12 14:07:45 +05:30
abhishek9686
773693568c resolve merge conflicts 2025-08-12 11:30:44 +05:30
Vishal Dalwadi
85c7da75d3
Fix: Use template variable correctly. (#3578)
* fix(go): use template variable correctly;

* feat(go): update docs link.

* feat(go): update docs link.
2025-08-12 09:17:21 +05:30
Vishal Dalwadi
062552170d
NM-24: IDP UX improvements (#3583)
* fix(go): parse error message when url.Error.

* fix(go): suppress intermediate errors and return the root cause.
2025-08-12 09:14:45 +05:30
Abhishek K
32657dde82
NM-9: User All resources Policy and relayed node acl Fix (#3592)
* user policies fix

* fix user acl rules for all resources tag

* handle relayed comms via gateway with active acl policies

* fix static node comms to all resources
2025-08-11 14:32:26 +05:30
Abhishek K
b972e7a969
add mutex on failover ops (#3590) 2025-08-11 12:17:11 +05:30
Vishal Dalwadi
e4da84aa85
NM-61: User group ACL fixes (#3546)
* feat(go): create default acl only for networks that are part of the group;

* feat(go): update acls on user group update and delete;

* feat(go): add migration for existing acls.

* feat(go): check for network roles in migration.
2025-08-08 22:17:39 +05:30
Vishal Dalwadi
996410fc61
NM-57: Graphs API Forbidden for Platform User (#3577)
* fix(go): permissions for network graph;

* fix(go): allow platform user to get network graph;

* feat(go): allow read only access to host resource to network users.

* feat(go): remove specific check for hosts resource.
2025-08-08 22:14:42 +05:30
Vishal Dalwadi
d5cc14ce49
Patch: Okta IDP Integration (#3586)
* feat(go): add support for okta.

* feat(go): update docs link.

* feat(go): handle okta.

* feat(go): handle okta.
2025-08-07 23:05:58 +05:30
Vishal Dalwadi
2f6817821c fix(go): avoid panic on client_email missing. 2025-07-31 21:58:45 +05:30
Vishal Dalwadi
025eebe7f2 fix(go): add okta to idp sync test. 2025-07-31 21:36:59 +05:30
Vishal Dalwadi
bca4565256 fix(go): idp sync status. 2025-07-31 21:27:15 +05:30
Vishal Dalwadi
0c43dd3788 feat(go): add verify method for okta idp client; 2025-07-30 19:29:47 +05:30