Commit 81642ef0 authored by Leigh Stoller's avatar Leigh Stoller

Add IsValidUUID().

parent df4887b7
......@@ -548,6 +548,15 @@ function NewUUID()
TBERROR("$UUIDGEN_PATH Failure", 1);
}
# Check pattern.
function IsValidUUID($token)
{
if (preg_match("/^\w+\-\w+\-\w+\-\w+\-\w+$/", $token)) {
return 1;
}
return 0;
}
function LASTNODELOGIN($node)
{
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment