MCPcopy Index your code
hub / github.com/SamNet-dev/snix / uuidToStr

Function uuidToStr

cfworker/worker.js:190–193  ·  view source on GitHub ↗
(b)

Source from the content-addressed store, hash-verified

188// -- helpers --------------------------------------------------------------
189
190function uuidToStr(b) {
191 const h = (n) => n.toString(16).padStart(2, "0");
192 return `${h(b[0])}${h(b[1])}${h(b[2])}${h(b[3])}-${h(b[4])}${h(b[5])}-${h(b[6])}${h(b[7])}-${h(b[8])}${h(b[9])}-${h(b[10])}${h(b[11])}${h(b[12])}${h(b[13])}${h(b[14])}${h(b[15])}`;
193}
194function isUUID(s) { return /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i.test(s); }
195function ipv6ToStr(b) {
196 const parts = [];

Callers 1

parseVLESSHeaderFunction · 0.85

Calls 1

hFunction · 0.85

Tested by

no test coverage detected