예제 #1
0
        public override Task <AccessReplyMessage> AccessRequest(AccessReqMessage request, ServerCallContext context)
        {
            string token = "";

            if (request.Name == "1" && request.Pass == "1")
            {
                token = SecUtility.GenerateJWT(request, config);
            }

            return(Task.FromResult(new AccessReplyMessage {
                Token = token
            }));
        }