﻿<html class="root-main" lang="en">
<head><meta name="renderer" content="webkit" />
    <meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta http-equiv="X-UA-Compatible" content="IE=EmulateIE11"><meta name="renderer" content="webkit"></head>

<script nonce="">
var __vpn_hostname_data = "m.bjycgold.com/webvpn";
var __vpn_protocol_data = "https";
var __vpn_protocol_host = "https://m.bjycgold.com/webvpn";
var __vpn_app_hostname_data = "77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d";
var __vpn_app_protocol_data = "https";
var __vpn_app_port_data = "";
var __vpn_js_file = "/wengine-vpn/js/main.js?ver=20211207";
var __vpn_worker_mode = 2;
var __vpn_fast_mode = 0;
var __vpn_host_crypt = true;
var __vpn_host_crypt_key = "wrdvpnisthebest!";
var __vpn_host_crypt_iv = "wrdvpnisthebest!";
var __vpn_hsts = false;
var __vpn_hsts_sub_domains = false;
</script>
<script src="/wengine-vpn/js/main.js?ver=20211207" charset="utf-8"></script>
<body id="bg" style=" background-size: 100% 100%; background-attachment: fixed;overflow: hidden">
<!-- 移动端 --><!-- PC端 --><!--校外用户登录--><!-- 二维码扫码登录 --><!-- 兼容性登录 --><!--校外用户登录--><!-- 帐号登录或动态码登录 --><title>统一身份认证平台</title>
<script>vpn_eval((function(){

    var inputUserNameTip = "\u8BF7\u8F93\u5165\u7528\u6237\u540D";
    var inputPasswordTip = "\u8BF7\u8F93\u5165\u5BC6\u7801";
    var inputCodeTip = "\u8BF7\u8F93\u5165\u9A8C\u8BC1\u7801";

    var inputMobileTip = "\u8BF7\u8F93\u5165\u624B\u673A\u53F7\u6216\u5B66\u53F7";
    var inputDynamicTip = "\u8BF7\u8F93\u5165\u9A8C\u8BC1\u7801";
    var inputDynamicGetCode = "\u83B7\u53D6\u9A8C\u8BC1\u7801";
    var excludeRegular = "\u7528\u6237\u540D\u5305\u542B\u7279\u6B8A\u5B57\u7B26";
    //不转码，防止参数丢失
    var service = null;
    var type = ["dynamicLogin"];
    var jsonObject = {
        "pcLogoPath": null,
        "pcThemeColor": null,
        "officialUrl": null,
        "defaultWxQrCode": 0,
        "wxQrCode": null,
        "defaultImage": 0,
        "imageType": 1,
        "shufflingTime": 5,
        "shufflingStyle": 2,
        "imageNames": ["default_login.png"],
        "mobileLogoPath": null,
        "mobileThemeColor": null,
        "mobileModel": 0,
        "mobileImages": ["default_mobile_login.png"],
        "otherModel": 0,
        "otherImages": ["default_auth_serv_bg.png"]
    };
    var reg = "[$:{}]";


}
).toString().slice(12, -2),"");</script>
<script type="text/javascript">vpn_eval((function(){

    //重新获取验证码
    function refresh(codeId) {
        $("#vcodeimg").attr("src", 'authImg?now=' + new Date().getTime() + '&refresh=1&authCodeKey=' + codeId);
    }


}
).toString().slice(12, -2),"");</script>
<script type="text/javascript">vpn_eval((function(){

    if (service == '' || !service) {
        service = '';//saml后缀
    }
    var isQrLogin = "true";
    var isQrLoginEnabled = "true"
    var captchaSwitch = "1";
    var needCaptcha = "";
    var _fidoEnabled = "true";
    var is_dynamicLogin = "true";
    var contextPath = "/authserver";
    var cllt = "";
    var _badCredentialsCount = "0";


}
).toString().slice(12, -2),"");</script>
<link rel="stylesheet" type="text/css" href="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/toastr.min.css?vpn-6"><link rel="stylesheet" type="text/css" href="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/login.css?vpn-6"><link rel="stylesheet" type="text/css" href="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/iconfont.css?vpn-6"><link rel="stylesheet" type="text/css" href="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/fido.css?vpn-6"><link rel="stylesheet" type="text/css" href="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/swiper.min.css?vpn-6"><script type="text/javascript" src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/swiper.min.js?vpn-7"></script>
<script type="text/javascript" src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/jquery-latest.min.js?vpn-7"></script>
<script type="text/javascript" src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/toastr.min.js?vpn-7"></script>
<script type="text/javascript" src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/utils.js?vpn-7"></script>
<script type="text/javascript" src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/common-header.js?vpn-7"></script>
<script type="text/javascript" src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/encrypt.js?vpn-7"></script>
<script type="text/javascript" src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/fido.js?vpn-7"></script>
<script type="text/javascript" src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/schoolCombinedLogin.js?vpn-7"></script>
<script type="text/javascript" src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/login.js?vpn-7"></script>
<style>
    iframe {
        height:290px!important;
        width: 280px!important;
    }
	#formErrorTip {
	 width: 230px!important;
	}
</style>

<img class="mainbg active" src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/bg1.jpg?vpn-1"><!--<img class="mainbg " src="./themes/nt/new/bg2.jpg">--><!--<img class="mainbg " src="./themes/nt/new/bg3.jpg">--><!--<div class="lunbo_nav">--><!--    <span class="active"></span>--><!--    <span class=""></span>--><!--    <span class=""></span>--><!--</div>--><div class="container content" style="display: none">
    <div class="dz_logo">
        <img class="dz_logo_img1" src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/logo.png?vpn-1"><img class="dz_logo_img2" src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/images/logo.png?vpn-1"><!--        <span class="tysfrz">统一身份认证</span>--></div>
    <div class="dz_language">
        <div class="dz_btn_box">
            <span id="dzzh" class="active" onclick="var vpn_return;eval(vpn_rewrite_js((function () { window.open(&#39;https://m.bjycgold.com/webvpn&#39;) }).toString().slice(14, -2), 2));return vpn_return;">校外访客</span>
            <span id="dzen" onclick="var vpn_return;eval(vpn_rewrite_js((function () { window.open(&#39;https://vpn.nipes.cn&#39;) }).toString().slice(14, -2), 2));return vpn_return;">VPN</span>
        </div>
    </div>
    <div class="wrap">
        <div class="dz_left">
            <div class="remark_box">
                <div class="dz_item">
                    <!--                    <p class="dz_title">统一身份认证系统</p>--><div class="dz_remark">
                        <p><span style="width: 32px;display: inline-block;"></span>按照网络安全等级保护要求，学校统一身份认证平台已进行了升级。
                        </p>
                        <p><span style="width: 32px;display: inline-block;"></span>此次升级实现“一个入口、一个门户”效果，所有校内外访问均只通过该平台（https://my.nsi.edu.cn）进入。
                        </p>
                        <p><span style="width: 32px;display: inline-block;"></span>如遇到原有密码无法登录，请使用初始化密码（身份证后六位，X需大写）进行登录，
                            并按照提示及时进行密码修改。若本页面自动刷新或无法输入账号信息，请清除浏览器缓存（<a href="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/img.html" target="_blank">点我查看方法</a>）后再次登录。
                        </p>
                        <p><span style="width: 32px;display: inline-block;"></span>使用过程中遇到问题，请咨询“智慧南体”服务热线：025-84755880。
                        </p>

                    </div>
                </div>
                <!--<div class="dz_item">
                    <p class="dz_title">融合门户</p>
                    <div class="dz_remark">
                        <p><span style="width: 32px;display: inline-block;"></span>新门户完成了服务场景从一元到多元的提升，将原本单一的门户页面提升为融合型平台，力求为师生带来更加场景化、个性化、智能化的门户体验。
                        </p>
                        <p><span style="width: 32px;display: inline-block;"></span><a href="https://i.nuist.edu.cn/" style="color:AliceBlue">登录</a></p>
                    </div>
                </div>--></div>
            <div class="dz_change">
                <img id="goPre" src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/left.png?vpn-1"><span class="dz_page"><a id="pageNum">1</a>/<a
                    id="pageTotal">2</a></span>
                <img id="goNext" src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/right.png?vpn-1"></div>
        </div>
        <a id="qrCodeA" class="qrcode" href="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e2559434357a467b1ac7a28d5c3021de5e41733d2b67/authserver/login?type=qrcode" style="display: none;"></a>
        <section class="main">
            <!-- <div class="logo"><img id="logo" alt=""/></div> --><div class="tabHead" style="">

                <span id="pwdLoginSpan" class="lang_text_ellipsis  selected_underline active" title="账号登录" style="text-overflow: ellipsis; overflow: hidden; white-space: nowrap; overflow-wrap: break-word; display: inline-block;"><a id="userNameLogin_a" class="loginFont_a" onclick="var vpn_return;eval(vpn_rewrite_js((function () { showType(&#39;pwd&#39;) }).toString().slice(14, -2), 2));return vpn_return;">账号登录</a></span>
                <span id="phoneLoginSpan" class="lang_text_ellipsis" title="短信登录" style="text-overflow: ellipsis; overflow: hidden; white-space: nowrap; overflow-wrap: break-word; display: inline-block;"><a id="dynamicLogin_a" class="loginFont_a" onclick="var vpn_return;eval(vpn_rewrite_js((function () { showType(&#39;phone&#39;) }).toString().slice(14, -2), 2));return vpn_return;">短信登录</a></span>
                <span id="qrcodeLoginSpan" class="lang_text_ellipsis" title="扫码登录" style="text-overflow: ellipsis; overflow: hidden; white-space: nowrap; overflow-wrap: break-word;"><a id="qrLogin_a" class="loginFont_a" onclick="var vpn_return;eval(vpn_rewrite_js((function () { showType(&#39;qrcode&#39;) }).toString().slice(14, -2), 2));return vpn_return;">扫码登录</a></span>
            </div>

            <div class="login-pwd showTypeBody">
                <!-- fido登录 --><!-- 手机动态码登录 --><!-- 用户名密码登录 --><div id="pwdLoginDiv" style="">
                    <div>
                        <div class="methods"></div>
                        <form method="post" class="loginFromClass" id="loginForm" action="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/login">
                            <input type="hidden" name="lt" value="${loginTicket}"/><input type="hidden" id="useVCode" name="useVCode" value=""/><input type="hidden" id="isUseVCode" name="isUseVCode" value="true"/><input type="hidden" id="sessionVcode" name="sessionVcode"
                                   value=""/><input type="hidden" id="errorCount" name="errorCount" value=""/><input type="hidden" name="execution" value="e1s1"/><input type="hidden" id="service" name="service" value="https://m.bjycgold.com/webvpn/login?cas_login=true"/><input type="hidden" name="_eventId" value="submit"/><input type="hidden" name="geolocation"/><div class="form">
                                <!-- 用户名密码登录 --><div class="m-account">
                                    <div class="username item">
                                        <span class="prex-icon"><img src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/user1.png?vpn-1" class="login-icon"></span>
                                        <input id="username" name="username" type="text" placeholder="请输入学号/工号"
                                               title="请输入学号/工号" accesskey="n" autocomplete="off"
                                               value=""/></div>
                                    <div class="password item">
                                        <span class="prex-icon"><img src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/pass1.png?vpn-1" class="login-icon"></span>
                                        <input id="password" name="password" type="password"
                                               placeholder="请输入密码" title="请输入密码" maxlength="32"
                                               accesskey="p"
                                               autocomplete="off" value=""/><!-- <a class="input_eye suffix-icon eyehide"></a> --></div>
                                    <div class="m-rememberMe lang_text_ellipsis" title="7天免登录" style="text-overflow: ellipsis; overflow: hidden; white-space: nowrap; overflow-wrap: break-word; display: inline-block;width: 98%;">
                                        <input type="checkbox" name="rememberpwd" id="rememberpwd" checked="checked" value="true" style="width:15px;margin-right:5px;"><span>记住密码</span>
                                        <a id="retrievePassId" href="/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/grzx/findpassword" target="_blank" style="float: right" class="fo-password">重置密码</a>
                                    </div>
                                </div>
                                <div class="btn">
                                    <a id="login_submit" href="javascript:void(0);" onclick="var vpn_return;eval(vpn_rewrite_js((function () { login() }).toString().slice(14, -2), 2));return vpn_return;" class="login-btn lang_text_ellipsis" title="登录" style="text-overflow: ellipsis; overflow: hidden; white-space: nowrap; overflow-wrap: break-word; display: inline-block;">登录</a>
                                </div>
                            </div>
                        </form>
                    </div>
                </div>

                <!-- 帐号激活|忘记密码 --><!-- <div class="help">
						<a id="activationAccountId" th:if="${_showAccountActivationLink}"
							th:href="@{../retrieve-password/accountActivation/index.html}" class="activation-account"
							th:text="#{login.page.account.activity.btn}"></a>
						<a id="retrievePassId" th:href="@{../retrieve-password/retrievePassword/index.html}"
							class="fo-password" th:text="#{login.page.forget.pwd}"></a>
					</div> --><!-- 在线帮助文档  --></div>
            <div class="login-phone showTypeBody" style="display: none">
                <!-- fido登录 --><!-- 手机动态码登录 --><div id="phoneLoginDiv" style="">
                    <div>
                        <div class="methods">
                        </div>
                        <form method="post" class="form-auto" id="sjloginForm" action="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/login">
                            <div id="sjdl">
                                <div class="form">
                                    <!-- 动态码登录 --><div id="userslist" style="width:240px;height:130px;display:none;overflow-y: auto;"></div>
                                    <div class="m-phone sjj">
                                        <div class="username item">
                                            <span class="prex-icon"><img src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/user1.png?vpn-1" class="login-icon"></span>
                                            <input type="text" id="phone" name="phone" autocomplete="off"
                                                   placeholder="请输入手机号" title="请输入手机号" value=""><a class="get-code lang_text_ellipsis " href="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/grzx/findUser" target="_blank" title="手机号查询" style="text-overflow: ellipsis; overflow: hidden; white-space: nowrap; overflow-wrap: break-word; display: inline-block;"><em
                                                    class="getCodeText">手机号查询</em></a>
                                        </div>
<!--                                        <div class="captcha item" id="captchaDiv1">--><!--                                            <span class="prex-icon"><img src="./themes/nt/new/captcha1.png"--><!--                                                                         class="login-icon"></span>--><!--                                            <input type="text" id="captcha1" name="captcha" placeholder="请输入验证码"--><!--                                                   title="请输入验证码" maxlength="10"><span class="captcha-img">--><!--								<img id="captchaImg" alt="验证码错误" height="30px"--><!--                                     src="./themes/nt/new/getCaptcha.htl"><a class="mask-inner captcha-refresh"--><!--                                                                             onclick="reloadCaptcha(true)"--><!--                                                                             href="javascript:void(0);">刷新</a>--><!--							</span>--><!--                                        </div>--><div class="code item">
                                            <span class="prex-icon"><img src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/pass1.png?vpn-1" class="login-icon"></span>
                                            <i class="auth_icon auth_icon_bar"></i>
                                            <input type="text" id="code" name="code"
                                                   placeholder="请输入短信验证码" title="请输入短信验证码"
                                                   maxlength="10"><a class="get-code lang_text_ellipsis  yxyzmbut hqyzm" href="javascript:void(0)" title="获取验证码" style="text-overflow: ellipsis; overflow: hidden; white-space: nowrap; overflow-wrap: break-word; display: inline-block;"><em class="getCodeText" onclick="var vpn_return;eval(vpn_rewrite_js((function () { getyxcode(this) }).toString().slice(14, -2), 2));return vpn_return;">获取验证码</em></a>
                                        </div>
                                    </div>
                                    <!-- <div class="phoneCode-remark lang_text_ellipsis" th:text="#{login.page.mobile.tip}"></div> --></div>
                                <div class="btn sjj">
                                    <a href="javascript:void(0);" class="login-btn lang_text_ellipsis" id="login_submit1" title="登录" style="text-overflow: ellipsis; overflow: hidden; white-space: nowrap; overflow-wrap: break-word; display: inline-block;" onclick="var vpn_return;eval(vpn_rewrite_js((function () { phonelogin() }).toString().slice(14, -2), 2));return vpn_return;">登录</a>
                                </div>
                            </div>
                        </form>
                    </div>
                </div>
                <!-- 用户名密码登录 --><!-- 帐号激活|忘记密码 --><!-- <div class="help">
						<a id="activationAccountId" th:if="${_showAccountActivationLink}"
							th:href="@{../retrieve-password/accountActivation/index.html}" class="activation-account"
							th:text="#{login.page.account.activity.btn}"></a>
						<a id="retrievePassId" th:href="@{../retrieve-password/retrievePassword/index.html}"
							class="fo-password" th:text="#{login.page.forget.pwd}"></a>
					</div> --><!-- 在线帮助文档  --></div>
            <!-- 嵌入二维码登录 --><div class="login-qrcode showTypeBody" style="display: none;">
                <div>
                    <script type="text/javascript" src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/qrcode.js?vpn-7"></script>
                    <div class="qr_scan_box">
                        <form method="post" id="qrLoginForm" action="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e2559434357a467b1ac7a28d5c3021de5e41733d2b67/authserver/login" role="form">
                            <div id="qr_code">
                                <div class="qr_scan_code">
                                    <div class="qr_scan_code" id="qrcode" style="margin-top:20px">

                                    </div>
                                </div>
                            </div>
                        </form>
                    </div>
                </div>
            </div>

                        <div class="footer" style="display: none">
                            <div class="other_top">
                                <img src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/qywx.png?vpn-1" style="margin-top: 30px;width: 140px;"></div>
                        </div>

<!--            <div class="footer" style="display: none">--><!--                <div class="other_top">--><!--                    <span class="dz_line lineleft"></span>--><!--                    <span>其他登录方式</span>--><!--                    <span class="dz_line lineright"></span>--><!--                </div>--><!--                <div class="other_item">--><!--                    <div class="ways">--><!--                        <div class="item">--><!--                            <a id="combinedLogin_a_qq"--><!--                               href="https://authserver.nuist.edu.cn/authserver/combinedLogin.do?type=qq">--><!--                                <img src="./themes/nt/new/QQ.png" alt=""></a>--><!--                            <div class="prompt">QQ登录</div>--><!--                        </div>--><!--                    </div>--><!--                    <div class="ways">--><!--                        <div class="item">--><!--                            <a id="combinedLogin_a_weiXin"--><!--                               href="https://authserver.nuist.edu.cn/authserver/combinedLogin.do?type=weixin">--><!--                                <img src="./themes/nt/new/weixin.png" alt=""></a>--><!--                            <div class="prompt">微信登录</div>--><!--                        </div>--><!--                    </div>--><!--                    <div class="ways">--><!--                        <div class="item">--><!--                            <a id="combinedLogin_a_email" href="https://deptmail.nuist.edu.cn/">--><!--                                <img src="./themes/nt/new/youxiang.png" alt=""></a>--><!--                            <div class="prompt">单位邮箱</div>--><!--                        </div>--><!--                    </div>--><!--                </div>--><!--            </div>--></section>

    </div>
    <!-- <div class="language_switch t_switch" style="z-index: 5;">
        <a id="commonLoginA" class="commonloginBtn lang_text_ellipsis" th:href="@{/login(type=commonLogin)}" th:if="${@systemConfigUtils.isCommonLoginEnabled()}" th:utext="#{ids.loginView.commonLogin}"></a>
        <select id="language" onchange="changeLanguage(this)" class="t_switch_list"></select>
    </div> --></div>
<!-- 滑块验证码 --><div id="sliderCaptchaDiv" style="width: 100%;height: 100%;display: none;"></div>
<div class="logining" style="z-index: 9999;position: absolute;display: none">登录中...</div>
<div class="footer_div" style="z-index: 9999;position: absolute;bottom: 10px;left: 40%;color: #777777">南京体育学院版权所有 Copyright ©2024</div>
<script src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421f1e25594693e7b59300d8db9d6562d/cas/themes/nt/new/login-language.js?vpn-7" type="text/javascript"></script>
<script type="text/javascript">vpn_eval((function(){

    $("#loginForm").attr("action","./login?service="+encodeURIComponent($("#service").val()))
    var service =encodeURIComponent($("#service").val());
    var redirect_uri = "";
    var hostUrl=window.location.href
    if(service=="${service}"||service==""){
        redirect_uri = encodeURIComponent("https://auth.nsi.edu.cn/cas/qywxLogin");
    }else{
        redirect_uri = encodeURIComponent("https://auth.nsi.edu.cn/cas/qywxLogin?service="+service);
    }
    console.log("redirect_uri===="+redirect_uri);
    var u = navigator.userAgent;
    // if(u.indexOf('wxwork')>0||u.indexOf('WeChat')>0){
    if(u.indexOf('wxwork')>0 && hostUrl.indexOf("webvpn") < 0){
        $(".logining").show();
        window.location.href="https://open.weixin.qq.com/connect/oauth2/authorize?" +
            "appid=ww7fb00a12dfd9478f" +
            "&redirect_uri=" +redirect_uri+
            "&response_type=code&scope=snsapi_userinfo" +
            "&agentid=1000095&state=1#wechat_redirect"
    }else {
        $(".content").show()
    }
    var qqredirect_uri=encodeURIComponent("https://auth.nsi.edu.cn/cas/qqLogin?service="+$("#service").val())
    var qqsrc="https://graph.qq.com/oauth2.0/authorize?response_type=code&client_id=101914353&redirect_uri="+qqredirect_uri+"&scope=get_user_info"
    $("#qq").attr("href",qqsrc)
    function openQrCode(){
        /*if(!window.WwLogin){
        var element = document.createElement("script");
        element.src = "https://rescdn.qqmail.com/node/ww/wwopenmng/js/sso/wwLogin-1.0.0.js";
        document.body.appendChild(element);
        for(var i=0;!window.WwLogin;i++){

        }

        }*/
        var dis = document.getElementById("qrcode").style.display;
        if(dis=="block"){
            $(".zclogin").show();
            document.getElementById("qrcode").style.display = "none";
        }else{
            $(".zclogin").hide();
            document.getElementById("wxqrcode").style.display = "none";
            document.getElementById("qrcode").style.display = "block";
            document.getElementById("qrcode").getElementsByTagName('iframe')[0].src=document.getElementById("qrcode").getElementsByTagName('iframe')[0].src;
        }
    }
    function openWxQrCode(){
        var dis = document.getElementById("wxqrcode").style.display;
        if(dis=="block"){
            $(".zclogin").show();
            document.getElementById("wxqrcode").style.display = "none";
        }else{
            $(".zclogin").hide();
            document.getElementById("qrcode").style.display = "none";
            document.getElementById("wxqrcode").style.display = "block";
            var redirect_uri=encodeURIComponent("https://auth.nsi.edu.cn/cas/wxLogin?service="+$("#service").val())
            var href=encodeURIComponent("https://auth.nsi.edu.cn/cas/themes/nt/css/login.css")
            var src="https://open.weixin.qq.com/connect/qrconnect?appid=wx5ba894dd7f2337a5&redirect_uri="
                +redirect_uri+"&response_type=code&scope=snsapi_login&state=STATE&href="
                +href+"#wechat_redirect"
            document.getElementById("wxqrcode").getElementsByTagName('iframe')[0].src=src;
        }
    }


    var flag = 0
    function Base64() {
        // private property
        _keyStr = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";
        // 公共编码方法
        this.encode = function (input) {
            var output = "";
            var chr1, chr2, chr3, enc1, enc2, enc3, enc4;
            var i = 0;
            input = _utf8_encode(input);
            while (i < input.length) {
                chr1 = input.charCodeAt(i++);
                chr2 = input.charCodeAt(i++);
                chr3 = input.charCodeAt(i++);
                enc1 = chr1 >> 2;
                enc2 = ((chr1 & 3) << 4) | (chr2 >> 4);
                enc3 = ((chr2 & 15) << 2) | (chr3 >> 6);
                enc4 = chr3 & 63;
                if (isNaN(chr2)) {
                    enc3 = enc4 = 64;
                } else if (isNaN(chr3)) {
                    enc4 = 64;
                }
                output = output +
                    _keyStr.charAt(enc1) + _keyStr.charAt(enc2) +
                    _keyStr.charAt(enc3) + _keyStr.charAt(enc4);
            }
            return output;
        }

        // 公共解码方法
        this.decode = function (input) {
            var output = "";
            var chr1, chr2, chr3;
            var enc1, enc2, enc3, enc4;
            var i = 0;
            input = input.replace(/[^A-Za-z0-9\+\/\=]/g, "");
            while (i < input.length) {
                enc1 = _keyStr.indexOf(input.charAt(i++));
                enc2 = _keyStr.indexOf(input.charAt(i++));
                enc3 = _keyStr.indexOf(input.charAt(i++));
                enc4 = _keyStr.indexOf(input.charAt(i++));
                chr1 = (enc1 << 2) | (enc2 >> 4);
                chr2 = ((enc2 & 15) << 4) | (enc3 >> 2);
                chr3 = ((enc3 & 3) << 6) | enc4;
                output = output + String.fromCharCode(chr1);
                if (enc3 != 64) {
                    output = output + String.fromCharCode(chr2);
                }
                if (enc4 != 64) {
                    output = output + String.fromCharCode(chr3);
                }
            }
            output = _utf8_decode(output);
            return output;
        }

        // UTF-8编码的私有方法
        _utf8_encode = function (string) {
            string = string.replace(/\r\n/g,"\n");
            var utftext = "";
            for (var n = 0; n < string.length; n++) {
                var c = string.charCodeAt(n);
                if (c < 128) {
                    utftext += String.fromCharCode(c);
                } else if((c > 127) && (c < 2048)) {
                    utftext += String.fromCharCode((c >> 6) | 192);
                    utftext += String.fromCharCode((c & 63) | 128);
                } else {
                    utftext += String.fromCharCode((c >> 12) | 224);
                    utftext += String.fromCharCode(((c >> 6) & 63) | 128);
                    utftext += String.fromCharCode((c & 63) | 128);
                }
            }
            return utftext;
        }

        // UTF-8解码的私有方法
        _utf8_decode = function (utftext) {
            var string = "";
            var i = 0;
            var c = c1 = c2 = 0;
            while ( i < utftext.length ) {
                c = utftext.charCodeAt(i);
                if (c < 128) {
                    string += String.fromCharCode(c);
                    i++;
                } else if((c > 191) && (c < 224)) {
                    c2 = utftext.charCodeAt(i+1);
                    string += String.fromCharCode(((c & 31) << 6) | (c2 & 63));
                    i += 2;
                } else {
                    c2 = utftext.charCodeAt(i+1);
                    c3 = utftext.charCodeAt(i+2);
                    string += String.fromCharCode(((c & 15) << 12) | ((c2 & 63) << 6) | (c3 & 63));
                    i += 3;
                }
            }
            return string;
        }
    }
    function login() {
        if ($("#rememberpwd")[0].checked) {
            saveUserPassword();
        } else {
            deleteCookie("bms_sso_username", "/");
            deleteCookie("bms_sso_password", "/");
        }
        if (flag == 0) {
            flag = 1;
            var base64=new Base64();
            var userName = $('#username').val();
            var password = $('#password').val();
            $('#username').val(base64.encode(base64.encode(userName)));
            $('#password').val(base64.encode(base64.encode(password)));
            $("#loginForm").submit();
            setTimeout(function (){
                $('#username').val(userName);
                $('#password').val(password);
            },10)


        }
    }

    $(function () {
        if (parent && parent != self) {
            top.window.location = window.location.href;
        }
        $('#vCode').val("");

        refresh('authCodeKeySSO');

        initUserPassword();
    });
    //cookier操作
    //保存到cookier
    function setCookie(name, value, hours, path) {
        var name = escape(name);
        var value = escape(value);
        var expires = new Date();
        expires.setTime(expires.getTime() + hours * 3600000);
        path = path == "" ? "" : ";path=" + path;
        _expires = (typeof hours) == "string" ? "" : ";expires=" + expires.toUTCString();
        document.cookie = name + "=" + value + _expires + path;
    }

    //删除cookie
    function deleteCookie(name, path) {
        var name = escape(name);
        var expires = new Date(0);
        path = path == "" ? "" : ";path=" + path;
        document.cookie = name + "=" + ";expires=" + expires.toUTCString() + path;
    }

    //获取cookie值
    function getCookieValue(name) {
        var name = escape(name);
        //读cookie属性，这将返回文档的所有cookie
        var allcookies = document.cookie;
        //查找名为name的cookie的开始位置
        name += "=";
        var pos = allcookies.indexOf(name);
        //如果找到了具有该名字的cookie，那么提取并使用它的值
        if (pos != -1) {                                             //如果pos值为-1则说明搜索"version="失败
            var start = pos + name.length;                  //cookie值开始的位置
            var end = allcookies.indexOf(";", start);        //从cookie值开始的位置起搜索第一个";"的位置,即cookie值结尾的位置
            if (end == -1) end = allcookies.length;        //如果end值为-1说明cookie列表里只有一个cookie
            var value = allcookies.substring(start, end);  //提取cookie的值
            return unescape(value);                           //对它解码
        } else return "";                                             //搜索失败，返回空字符串
    }

    //保存用户名密码
    function saveUserPassword() {
        var base64=new Base64();
        var userName = $.trim(document.getElementById("username").value);
        setCookie("bms_sso_username", base64.encode(base64.encode(userName)), 24 * 7, "/");
        var password = $.trim(document.getElementById("password").value);
        setCookie("bms_sso_password", base64.encode(base64.encode(password)), 24 * 7, "/");
    }

    //初始化用户名密码
    function initUserPassword() {
        var base64=new Base64();
        var userName = getCookieValue("bms_sso_username");
        var password = getCookieValue("bms_sso_password");
        $('#username').val(base64.decode(base64.decode(userName)));
        $('#password').val(base64.decode(base64.decode(password)));
        if (userName && userName.length > 0) {
            document.getElementById("password").focus();
        }
    }

    var JPlaceHolder = {
        //检测
        _check: function () {
            return 'placeholder' in document.createElement('input');
        },
        //初始化
        init: function () {
            if (!this._check()) {
                this.fix();
            }
        },
        //修复
        fix: function () {
            jQuery(':input[placeholder]').each(function (index, element) {
                var self = $(this), txt = self.attr('placeholder');
                self.wrap($('<div></div>').css({
                    position: 'relative',
                    zoom: '1',
                    border: 'none',
                    background: 'none',
                    padding: 'none',
                    margin: 'none'
                }));
                var pos = self.position(), h = self.outerHeight(true), paddingleft = self.css('padding-left');
                var holder = $('<span style="margin-top:32px;margin-left: 33px"></span>').text(txt).css({
                    position: 'absolute',
                    left: pos.left,
                    top: pos.top,
                    height: 42,
                    lienHeight: h,
                    paddingLeft: 0,
                    color: '#aaa'
                })
                    .appendTo(self.parent());
                if (!self.val()) {
                    holder.show();
                } else {
                    holder.hide();
                }
                self.focusin(function (e) {
                    holder.hide();
                }).focusout(function (e) {
                    if (!self.val()) {
                        holder.show();
                    }
                });
                holder.click(function (e) {
                    holder.hide();
                    self.focus();
                });
            });
        }
    };
    //执行
    jQuery(function () {
        JPlaceHolder.init();
    });

    var s;
    function getyxcode(e) {
        var yxnumber = $("#phone").val();
        if(yxnumber.length==0){
            alert( "手机号不能为空");
            $("#phone").focus();
            return;
        }else{
            $.ajax({
                url : "./pl/sendCode",
                type:"get",
                data:{"phone":yxnumber,"service":$("#service").val()},
                dataType:"json",
                async:false,
                success:function(data, status, XHR){
                    if(data!=null&&data>0){
                        s = setInterval(function () {
                            yxcountdown(e)
                        }, 1000)
                        yxcountdown(e);
                    }else if(data!=null&&data==-1){
                        alert( "未找到此手机号或手机号错误");
                        return;
                    }else if(data!=null&&data==-2){
                        alert( "获取验证码过于频繁");
                        return;
                    }else{
                        alert( "获取验证码失败");
                        return;
                    }
                },
                error:function(){
                    alert( "获取验证码失败");
                    return;
                }
            });

        }
    }

    var ytime = 60;
    function yxcountdown(e){
        if (ytime == 0) {
            //这里时设置当时间到0的时候重新设置点击事件，并且默认time修改为60
            e.setAttribute("onclick","getyxcode(this)");
            $(".yxyzmbut").text("发送验证码");
            ytime = 60;
            clearInterval(s);
        }else{
            //这里是显示时间倒计时的时候点击不生效
            e.setAttribute("onclick", '');
            $(".yxyzmbut").text("重新发送"+ytime);
            ytime--;
        }
    }

    function phonelogin(){
        var yxnumber = $("#phone").val()
        if(yxnumber.length==0){
            alert( "手机号不能为空");
            $("#phone").focus();
            return;
        }
        if(checkPhone(yxnumber)){
            alert("手机号码有误，请重填");
            $("#phone").focus();
            return;
        }
        var yzm = $("#code").val()
        if(yzm.length==0){
            alert( "验证码不能为空");
            $("#code").focus();
            return;
        }

        $.ajax({
            url : "./pl/checkCode",
            type:"get",
            data:{"phone":yxnumber,"code":yzm},
            dataType:"json",
            async:false,
            success:function(data, status, XHR){
                if(data!=null&&data>0){
                    showUser(yxnumber,yzm)
                }else{
                    alert( "验证码不正确");
                    return;
                }
            },
            error:function(){
                alert( "校验失败");
                return;
            }
        });
    }

    function checkPhone(phone){
        if(!(/^1[3456789]\d{9}$/.test(phone))){
            return true;
        }
        return false;
    }

    function showUser(phone,code){
        $.ajax({
            url : "./pl/showUsers",
            type:"get",
            data:{"phone":phone},
            dataType:"json",
            async:false,
            success:function(data, status, XHR){
                if(data!=null&&data.length==1){
                    phoneLogin(data[0].USERID,phone,code)
                }else if(data!=null&&data.length>0){
                    $("#sjdl").html("");
                    var str = '';
                    var first=0;
                    for (var s in data) {
                        var userid = data[s].USERID;
                        var name = data[s].CN;
                        var mg=""
                        if(first==0){
                            mg="style=\"margin-top:70px\""
                        }
                        str+='<div class="btn sjj" '+mg+'><a href="javascript:void(0);" class="login-btn lang_text_ellipsis"' +
                            ' style="text-overflow: ellipsis; overflow: hidden; white-space: nowrap; overflow-wrap: break-word; display: inline-block;"' +
                            ' onclick="phoneLogin(\''+userid+'\',\''+phone+'\',\''+code+'\')">登录'+name+'</a></div>'
                    }
                    $("#sjdl").append(str);
                }else{
                    alert( "未找到此手机号或手机号错误");
                    return;
                }
            },
            error:function(){
                alert( "查询失败");
                return;
            }
        });
    }

    function phoneLogin(userName,phone,code) {
        window.location.href = "./pl/phoneLogin?service="+encodeURIComponent($("#service").val())+"&userName="+userName+"&phone="+phone+"&code="+code;
    }

    function zhmmdl(){
        $("#zhmm").show();
        $("#sj").hide();
    }
    function sjhdl(){
        $("#sj").show();
        $("#zhmm").hide();
    }



}
).toString().slice(12, -2),"");</script>
<script src="https://m.bjycgold.com/webvpn/https/77726476706e69737468656265737421e2f2529f233e26416f0588a5941b203a8f/node/ww/wwopenmng/js/sso/wwLogin-1.0.0.js?vpn-7" type="text/javascript"></SCRIPT>
<script>vpn_eval((function(){

    window.WwLogin({
        "id": "qrcode",
        "appid": "ww7fb00a12dfd9478f",
        "agentid": "1000095",
        "redirect_uri": redirect_uri,
        "state": "",
        "href" : "https://id.cpu.edu.cn/sso/themes/cpu/css/login.css",
    });


}
).toString().slice(12, -2),"");</script>
</body>
</html>