Commit graph

77 commits

Author SHA1 Message Date
Aceix
39fbb45cfe
feat(NET-817): add postup/down scripts for clients (#2810) 2024-02-08 23:29:43 +05:30
Abhishek K
5bf30b2c10
NET-877: Replace peers on Refreshkeys peer update (#2761)
* replace peers on key refresh

* add peer conf to metrics map only when allowed
2024-01-11 15:59:19 +05:30
Abhishek K
797f3a4533
Send deleted extclient mq update when disabled (#2760) 2024-01-10 14:57:29 +05:30
Abhishek K
7e3bf3baea
NET-812: Deprecate Setting /etc/hosts entries (#2733)
* deprecate setting etc host dns entries, set coredns entries at neccessary places

* remove dns mq topics

* only set dns when set on

* add extcleints dns entries to coredns

* fix static checks

* run coredns with host network mode

* add bind address to coredns container
2023-12-20 10:24:53 +04:00
Aceix
72f84c1355
feat(NET-810): add RAC support for admins (#2731)
admins and superadmins can access and connect to any ingress
different users cannot connect to the same ingress with the same remote device
2023-12-20 08:56:30 +04:00
Abhishek K
530dbdc65c
NET-710: Internet Gws Re-Design (#2718)
* add internet gateway to client gateway

* migration func to remove internet egress range from egress gateway

* add internet gateways ranges to firewall update

* add internet gw ranges to extcleint conf

* add ipv6 internet address

* remove failover field from ingress req

* only let normal to be created on PRO (#2716)

* feat(NET-805): send internet gw props to rac

* set inet gw field on node update api

* move internet gws to EE

---------

Co-authored-by: the_aceix <aceixsmartx@gmail.com>
2023-12-06 23:57:58 +04:00
Abhishek Kondur
358bd12297 send peer update for extclient extraAllowedIps update 2023-11-27 10:03:21 +04:00
Abhishek K
4876bdb62f
NET-674: clear extclients of an user when deleted, remove gw id from user gws when deleted (#2631)
* remove client gw from user when deleted

* clear extclient of a user if deleted

* check if ingress gw on user gws

* debug log

* log change

* pr comments
2023-10-17 23:22:17 +04:00
Matthew R Kasun
876778a1cc
open api spec file (#2595)
* remove usergroup

* superadmin

* superadmin creation

* generate openapi spec file

* statticcheck

* review comments
2023-10-04 10:26:38 +04:00
Matthew R Kasun
622eb9899b
do not check for network header (#2599) 2023-09-28 14:28:56 +04:00
Farukh Khan
7c4870e82f
NET-600 (#2571)
* NET-600

* Ext clients dns now properly set from ingress dns value provided that the individual ext client dns are not present.

* NET-468 & NET-600

* When individual extclient dns is changed or removed, it reflects on the UI properly and also gets updated on backend.
2023-09-18 09:58:04 +02:00
Abhishek K
719e0c254d
NET-551: User Mgmt Re-Design (#2547)
* add superadmin role, apis to create superadmin user

* apis to attach and remove user from remote access gateways

* add api to list user's remote client has gateway clients

* remove code related user groups

* remove networks and groups from user model

* refactor user CRUD operations

* fix network permission test

* add superadmin to authorize func

* remove user network and groups from cli

* api to transfer superadmin role

* add api to list users on a ingress gw

* restrict user access to resources on server

* deny request from remote access client if extclient is already created

* fix user tests

* fix static checks

* fix static checks

* add limits to extclient create handler

* set username to superadmin on if masterkey is used

* allow creation of extclients using masterkey

* add migration func to assign superadmin role for existing admin user

* check for superadmin on migration if users are present

* allowe masterkey to extcleint apis

* check ownerid

* format error, on jwt token verification failure return unauthorized rather than forbidden

* user update fix

* move user remote functionality to ee

* fix update user api

* security patch

* initalise ee user handlers

* allow user to use master key to update any user

* use slog

* fix auth user test

* table headers

* remove user role, it's covered in middleware

* setuser defaults fix
2023-09-01 14:27:08 +05:30
Farukh Khan
8be0409b6a
NET-555 (#2524)
* IoT peer updates remove flag is now only triggering on relay deletion. Not triggering on extclients deletion anymore.

* Small typo fix on publish dns update for new extclient function name.
2023-08-25 14:23:01 +05:30
Gabriel de Souza Seibel
8ce7da2ce9
[NET-494 / ACC-322] New free tier limits (#2495)
* Rename var

* Rename consts and use iota

* Use switch instead of repeated else if

* Rename limits related vars

* Introduce new free tier limits

* Measure new limits and report on license validation

* Separate usage and limits, have new ones

* Don't check for hosts and clients limits, but for machines instead

* Error on egress creation @ free tier w/ internet gateways

* Remove clients and hosts limit from code

* Rename var

* Rename consts and use iota

* Use switch instead of repeated else if

* Rename limits related vars

* Introduce new free tier limits

* Measure new limits and report on license validation

* Separate usage and limits, have new ones

* Don't check for hosts and clients limits, but for machines instead

* Error on egress creation @ free tier w/ internet gateways

* Remove clients and hosts limit from code
2023-08-08 23:17:49 +05:30
Farukh Khan
449f3f947b
Net 509 515 (#2496)
* NET-509

* External client config files with IPv6 endpoints now have the [] separating the address and port.

* NET-515

* Increased network name max length to 32

* NET-509-515

* Updated unit test for network name max length check.

* Updated extclient endpoint ip string manipulation to use sprintf

* Added proper error message for network name length more than max allowed.

* NET-515 small typo fix for error strings should not be capitalized
2023-08-08 23:17:22 +05:30
Matthew R Kasun
0c70c4daba
enforce unique names for ext client names (#2476)
* enforce unique names for ext client names

* only check for unique id on creation

* check for unique id if changed
2023-08-01 20:20:43 +05:30
Abhishek K
645bc4c126
NET-447: Removed proxy related fields and code (#2459)
* remove related fields and code

* remover metrics collection from server code

* fw update struct

* add ext client flag to metrics data

* simply nat types

* rm proxy update from cli
2023-07-26 11:22:49 +05:30
Aceix
f4a5520f86
Kwesi/net 326 bug client ac ls (#2462)
* feat(NET-326): return 200 [] instead of 500 when there are not network acls

* fix(NET-326): implement allow/deny client acl functions

* fix(NET-326): implement extclient acl update

* fix(NET-326): kame fixes, send peer updates
2023-07-26 10:32:54 +05:30
Abhishek Kondur
50e093b456 cache ext clients 2023-06-27 20:48:53 +05:30
Matthew R Kasun
78640f1342
Extclient NET-63x (#2286)
* model changes

* additional fields for extclient create

* add DNS to extclient config

* extclient name checks

* update extclient

* nmctl extclient

* final tweaks

* review comments

* add extclientdns to node on ingress creation

* fix to add ingress dns to api (#2296)

---------

Co-authored-by: Aceix <aceixsmartX@gmail.com>
2023-05-17 10:58:03 -04:00
walkerwmanuel
9e56135424 Added user sorting and fixed error 2023-04-03 14:36:38 -04:00
walkerwmanuel
09872e9ec5 added sort logic 2023-03-30 16:04:12 -04:00
Abhishek Kondur
60ddad3189 proxy only required connections 2023-03-28 14:04:27 +04:00
0xdcarns
0f3faceb93 added logic for ext client ACLs 2023-03-14 13:39:33 -04:00
0xdcarns
55b24c5eeb allowed public key input for ext clients 2023-03-06 15:54:50 -05:00
0xdcarns
80fda83c0c adjusted peer updates to remove peers properly, slowed zombie check 2023-02-23 10:55:42 -05:00
Matthew R Kasun
bd9cf14c02 Merge branch 'develop' into gra-1088_dns_updates 2023-02-15 06:42:09 -05:00
Abhishek Kondur
6e59eae1ef get right listen for ext conf file 2023-02-12 15:08:08 +04:00
Matthew R Kasun
543c2e9c91 send correct existing name on extclient update 2023-02-08 13:32:11 -05:00
Matthew R Kasun
d4cd24e778 extclient update 2023-02-08 11:32:28 -05:00
Matthew R Kasun
488ada670c cleanup: function comments, etc 2023-02-07 15:17:11 -05:00
Matthew R Kasun
b9accde5b2 ensure publish dns in go routine 2023-02-07 15:17:11 -05:00
Matthew R Kasun
d857ca1148 publish dns update on ext client update 2023-02-07 15:17:11 -05:00
Matthew R Kasun
89136f4832 publish dns update on ext client deletion 2023-02-07 15:17:10 -05:00
Abhishek Kondur
e9dd9ac0a4 fix fetching uniqueIp 2023-01-13 19:11:40 +05:30
Matthew R. Kasun
8bfe255eab Merge remote-tracking branch 'origin/develop' into netclient_refactor_latest
Signed-off-by: Matthew R. Kasun <mkasun@nusak.ca>
2023-01-04 14:16:12 -05:00
walkerwmanuel
6611941ca2 Replaced string methods with HTTP consts 2022-12-23 09:49:08 -05:00
Matthew R. Kasun
bce2f8a45c fix compile errors 2022-12-22 06:42:33 -05:00
theguy951357
ac239d014a changed to validate on update 2022-12-21 14:11:52 -05:00
Anish Mukherjee
611fc53d5e do not validate empty ext client ids 2022-12-21 22:23:37 +05:30
Matthew R. Kasun
38cd4d7700 refactor join
also removes server node
suspect there may be issues with proxy
and UI interactions with nodes
2022-12-20 15:29:09 -05:00
Abhishek Kondur
07dd20734d extclients internal ips 2022-12-12 22:49:35 +05:30
Abhishek Kondur
8fc09fd5cd fix stun port format,use proxy listen port from node model 2022-12-12 10:33:35 +05:30
Abhishek Kondur
d8075e69c6 add alias internal ip to ext clients 2022-12-08 19:48:47 +05:30
Anish Mukherjee
8cbe7cb186 allow only dashes and alphanumeric for node and ext client names 2022-12-08 17:51:42 +05:30
Abhishek Kondur
cff3508425 Merge branch 'develop' of https://github.com/gravitl/netmaker into feature_proxy_metrics 2022-12-01 19:31:56 +05:30
Abhishek Kondur
972ded5a2d change listen port to proxy on ext client creation if proxy used on ingress GW 2022-11-27 22:22:54 +05:30
0xdcarns
ea854a6b98 fixed admin issue and potential panics 2022-11-10 14:54:53 -05:00
afeiszli
b670755cce refactoring for ee 2022-09-14 13:26:31 -04:00
0xdcarns
88cd0a6497 initial commit 2022-09-13 15:25:56 -04:00