Want to show it in UIs. So need to get it via API.
It's also a pain to look up. You have to go to external docs.
zerotier-cli info -j
```json
"config": {
"settings": {
"allowTcpFallbackRelay": true,
"forceTcpRelay": true,
"homeDir": "/Library/Application Support/ZeroTier/One",
```
```sh
curl -s -X POST "http://localhost:9993/controller/network/abcdabcdabcdabcd/member/1122334455"
```
Would return 200 and ZT_HOME/controller.d/abcdabcdabcdabcd/members/1122334455
would be created. Without a ZT_HOME/controller.d/abcdabcdabcdabcd.json
Then other parts of the system mistakenly think a abcdabcdabcdabcd
network sorta kinda exists and then fail in weird ways.
There was as Windows directory traversal bug in the static
file server feature. We don't use that feature, so we are ok.
We are going to use that feature soon, so we are
taking the opportunity to update.
Add /unstable/controller/network endpoint
Similar to /unstable/controller/network/{id}/member, it returns actual network objects,
instead of just network ids.
Also includes the total network count,
and each network has it's member counts in meta{}.
The current api at /controller/network/1111111111767f2f/member
Lists only the members' ID and revision number.
If you want details, you have to query each specific member.
So if you want to make a members list, and you have
10000 members on a network, you need to make
10000 http requests.
It's also in a hard to specify and use shape
{ [member-id-1]: 13, [member-id-2]: 14, ... }
GET http://localhost:9993/unstable/controller/network/1111111111767f2f/member ->
```
{
data: [ {...member1}, {...member2}, ...],
meta: { totalCount: 4, authorizedCount: 3 }
}
```
It wasn't ignoring separator characters such as the colon and hyphen.
The rules compiler automatically add a colon to separate bytes, which is
not compatible with how they are parsed.
* Better compatibility with LLVM toolchain where clang -c doesn't
support the flag, but the linker does. LLD already defaults to
noexecstack, but adding it in the linker phase will avoid errors about
unsupported options.
Signed-off-by: Alfred Wingate <parona@protonmail.com>