if(args.Length()!=2&&args.Length()!=3)returnVException("Requires a GSS context, optional challenge string and callback function");
if(args.Length()==2&&!KerberosContext::HasInstance(args[0]))returnVException("Requires a GSS context, optional challenge string and callback function");
if(args.Length()==3&&!KerberosContext::HasInstance(args[0])&&!args[1]->IsString())returnVException("Requires a GSS context, optional challenge string and callback function");
if(args.Length()!=2&&args.Length()!=3)returnVException("Requires a GSS context, optional challenge string and callback function");
if(args.Length()==2&&!KerberosContext::HasInstance(args[0])&&!args[1]->IsFunction())returnVException("Requires a GSS context, optional challenge string and callback function");
if(args.Length()==3&&!KerberosContext::HasInstance(args[0])&&!args[1]->IsString()&&!args[2]->IsFunction())returnVException("Requires a GSS context, optional challenge string and callback function");
if(args.Length()!=3&&args.Length()!=4)returnVException("Requires a GSS context, the result from the authGSSClientResponse after authGSSClientUnwrap, optional user name and callback function");
if(args.Length()==3&&!KerberosContext::HasInstance(args[0])&&!args[1]->IsString()&&!args[2]->IsFunction())returnVException("Requires a GSS context, the result from the authGSSClientResponse after authGSSClientUnwrap, optional user name and callback function");
if(args.Length()==4&&!KerberosContext::HasInstance(args[0])&&!args[1]->IsString()&&!args[2]->IsString()&&!args[2]->IsFunction())returnVException("Requires a GSS context, the result from the authGSSClientResponse after authGSSClientUnwrap, optional user name and callback function");