国产 无码 综合区,色欲AV无码国产永久播放,无码天堂亚洲国产AV,国产日韩欧美女同一区二区

【navicat 密碼查看】小技巧navicat 如何查看密碼

這篇具有很好參考價值的文章主要介紹了【navicat 密碼查看】小技巧navicat 如何查看密碼。希望對大家有所幫助。如果存在錯誤或未考慮完全的地方,請大家不吝賜教,您也可以點擊"舉報違法"按鈕提交疑問。

時間久了,當(dāng)我們以前連上了navicat 之后,密碼忘記了,但是依然能連接,此時我們想查看密碼,應(yīng)該如何操作呢?

步驟1:點擊navicat 文件選項,導(dǎo)出連接,勾選需要導(dǎo)出的數(shù)據(jù)庫,導(dǎo)出的時候一定要勾選導(dǎo)出密碼
【navicat 密碼查看】小技巧navicat 如何查看密碼,數(shù)據(jù)庫--greenplum,數(shù)據(jù)開發(fā)-mysql,javascript,php,java

導(dǎo)出之后,我們會得到一個connections.ncx文件中找到password,然后復(fù)制出來

【navicat 密碼查看】小技巧navicat 如何查看密碼,數(shù)據(jù)庫--greenplum,數(shù)據(jù)開發(fā)-mysql,javascript,php,java
復(fù)制出來password內(nèi)容

然后我們要對這個password 密碼進行解密。打開小工具 網(wǎng)站:

小工具解密網(wǎng)站

將如下PHP代碼復(fù)制進去:

<?php
class NavicatPassword
{
    protected $version = 0;
    protected $aesKey = 'libcckeylibcckey';
    protected $aesIv = 'libcciv libcciv ';
    protected $blowString = '3DC5CA39';
    protected $blowKey = null;
    protected $blowIv = null;
     
    public function __construct($version = 12)
    {
        $this->version = $version;
        $this->blowKey = sha1('3DC5CA39', true);
        $this->blowIv = hex2bin('d9c7c3c8870d64bd');
    }
     
    public function encrypt($string)
    {
        $result = FALSE;
        switch ($this->version) {
            case 11:
                $result = $this->encryptEleven($string);
                break;
            case 12:
                $result = $this->encryptTwelve($string);
                break;
            default:
                break;
        }
         
        return $result;
    }
     
    protected function encryptEleven($string)
    {
        $round = intval(floor(strlen($string) / 8));
        $leftLength = strlen($string) % 8;
        $result = '';
        $currentVector = $this->blowIv;
         
        for ($i = 0; $i < $round; $i++) {
            $temp = $this->encryptBlock($this->xorBytes(substr($string, 8 * $i, 8), $currentVector));
            $currentVector = $this->xorBytes($currentVector, $temp);
            $result .= $temp;
        }
         
        if ($leftLength) {
            $currentVector = $this->encryptBlock($currentVector);
            $result .= $this->xorBytes(substr($string, 8 * $i, $leftLength), $currentVector);
        }
         
        return strtoupper(bin2hex($result));
    }
     
    protected function encryptBlock($block)
    {
        return openssl_encrypt($block, 'BF-ECB', $this->blowKey, OPENSSL_RAW_DATA|OPENSSL_NO_PADDING);
    }
     
    protected function decryptBlock($block)
    {
        return openssl_decrypt($block, 'BF-ECB', $this->blowKey, OPENSSL_RAW_DATA|OPENSSL_NO_PADDING);
    }
     
    protected function xorBytes($str1, $str2)
    {
        $result = '';
        for ($i = 0; $i < strlen($str1); $i++) {
            $result .= chr(ord($str1[$i]) ^ ord($str2[$i]));
        }
         
        return $result;
    }
     
    protected function encryptTwelve($string)
    {
        $result = openssl_encrypt($string, 'AES-128-CBC', $this->aesKey, OPENSSL_RAW_DATA, $this->aesIv);
        return strtoupper(bin2hex($result));
    }
     
    public function decrypt($string)
    {
        $result = FALSE;
        switch ($this->version) {
            case 11:
                $result = $this->decryptEleven($string);
                break;
            case 12:
                $result = $this->decryptTwelve($string);
                break;
            default:
                break;
        }
         
        return $result;
    }
     
    protected function decryptEleven($upperString)
    {
        $string = hex2bin(strtolower($upperString));
         
        $round = intval(floor(strlen($string) / 8));
        $leftLength = strlen($string) % 8;
        $result = '';
        $currentVector = $this->blowIv;
         
        for ($i = 0; $i < $round; $i++) {
            $encryptedBlock = substr($string, 8 * $i, 8);
            $temp = $this->xorBytes($this->decryptBlock($encryptedBlock), $currentVector);
            $currentVector = $this->xorBytes($currentVector, $encryptedBlock);
            $result .= $temp;
        }
         
        if ($leftLength) {
            $currentVector = $this->encryptBlock($currentVector);
            $result .= $this->xorBytes(substr($string, 8 * $i, $leftLength), $currentVector);
        }
         
        return $result;
    }
     
    protected function decryptTwelve($upperString)
    {
        $string = hex2bin(strtolower($upperString));
        return openssl_decrypt($string, 'AES-128-CBC', $this->aesKey, OPENSSL_RAW_DATA, $this->aesIv);
    }
};
 
 
//需要指定版本兩種,11或12
//$navicatPassword = new NavicatPassword(11);
//這里我指定的12的版本,原先指定的11,執(zhí)行之后的密碼是亂碼
$navicatPassword = new NavicatPassword(12);
 
//解密
//$decode = $navicatPassword->decrypt('15057D7BA390');
$decode = $navicatPassword->decrypt('AE137B98AB3AD0F913EBEF2E8D3C52E9');
echo $decode."\n";
?>

點擊執(zhí)行,右邊運行得到密碼。
【navicat 密碼查看】小技巧navicat 如何查看密碼,數(shù)據(jù)庫--greenplum,數(shù)據(jù)開發(fā)-mysql,javascript,php,java

方法2:可以使用python 代碼。

navicat 加密方式文章來源地址http://www.zghlxwxcb.cn/news/detail-552074.html

# -*- coding: utf-8 -*-

from Crypto.Cipher import AES
from binascii import b2a_hex, a2b_hex


# 如果text不足16位的倍數(shù)就用空格補足為16位
def add_to_16(text):
    if len(text.encode('utf-8')) % 16:
        add = 16 - (len(text.encode('utf-8')) % 16)
    else:
        add = 0
    text = text + ('\0' * add)
    return text.encode('utf-8')


# 加密函數(shù)
def encrypt(text):
    key = 'libcckeylibcckey'.encode('utf-8')
    mode = AES.MODE_CBC
    iv = b'libcciv libcciv '
    text = add_to_16(text)
    cryptos = AES.new(key, mode, iv)
    cipher_text = cryptos.encrypt(text)
    print(b2a_hex(cipher_text))
    # 因為AES加密后的字符串不一定是ascii字符集的,輸出保存可能存在問題,所以這里轉(zhuǎn)為16進制字符串
    return b2a_hex(cipher_text)


# 解密后,去掉補足的空格用strip() 去掉
def decrypt(text):
    key = 'libcckeylibcckey'.encode('utf-8')
    iv = b'libcciv libcciv '
    mode = AES.MODE_CBC
    cryptos = AES.new(key, mode, iv)
    plain_text = cryptos.decrypt(a2b_hex(text))
    return bytes.decode(plain_text).rstrip('\0').replace('','')



if __name__ == '__main__':
    # e=encrypt('root')
    d = decrypt('AE137B98AB3AD0F913EBEF2E8D3C52E9')  # 解密
    # print("加密:",e)
    print("解密:", d)



解密: hzjy&flzx3qc

Process finished with exit code 0

到了這里,關(guān)于【navicat 密碼查看】小技巧navicat 如何查看密碼的文章就介紹完了。如果您還想了解更多內(nèi)容,請在右上角搜索TOY模板網(wǎng)以前的文章或繼續(xù)瀏覽下面的相關(guān)文章,希望大家以后多多支持TOY模板網(wǎng)!

本文來自互聯(lián)網(wǎng)用戶投稿,該文觀點僅代表作者本人,不代表本站立場。本站僅提供信息存儲空間服務(wù),不擁有所有權(quán),不承擔(dān)相關(guān)法律責(zé)任。如若轉(zhuǎn)載,請注明出處: 如若內(nèi)容造成侵權(quán)/違法違規(guī)/事實不符,請點擊違法舉報進行投訴反饋,一經(jīng)查實,立即刪除!

領(lǐng)支付寶紅包贊助服務(wù)器費用

相關(guān)文章

  • 如何通過navicat連接SQL Server數(shù)據(jù)庫

    如何通過navicat連接SQL Server數(shù)據(jù)庫

    ? ? ? ?本文介紹如何通過Navicat 連接SQL Server數(shù)據(jù)庫。如果想了解如何連接Oracle數(shù)據(jù)庫,可以參考下邊這篇文章。 如何通過Navicat連接Oracle數(shù)據(jù)庫 https://sgknight.blog.csdn.net/article/details/132064235 1、新建SQL Server連接配置 ? ? ? ? 打開Navicat軟件,點擊連接,選擇SQL server,進入配置頁

    2024年02月04日
    瀏覽(93)
  • 如何把Navicat中的數(shù)據(jù)庫中的所有表導(dǎo)出

    如何把Navicat中的數(shù)據(jù)庫中的所有表導(dǎo)出

    第一步 打開navicat 找到你想要導(dǎo)出表的數(shù)據(jù)庫 第二步 右擊該數(shù)據(jù)庫,選擇 轉(zhuǎn)儲SQL文件 再選擇 結(jié)構(gòu)和數(shù)據(jù)… 保存到一個你知道的文件夾中,就ok了。 第三步 運行那個生成的文件,就可生成之前數(shù)據(jù)庫中的所有表格了,通過記事本打開那個文件,復(fù)制所有的代碼。 第四步 在

    2024年02月07日
    瀏覽(24)
  • 如何根據(jù)需求選擇合適的數(shù)據(jù)庫管理工具?Navicat OR DBeaver

    1.寫在前面 在閱讀本文之前,糖糖給大家準(zhǔn)備了Navicat和DBeaver安裝包,在公眾號內(nèi)回復(fù)“Navicat”或“DBeaver”或\\\"數(shù)據(jù)庫管理工具\\\"來下載。 2. 引言 對于測試而言,在實際工作中往往會用到數(shù)據(jù)庫,那么選擇使用哪種類型的數(shù)據(jù)庫管理工具顯的尤為重要,我們常用的數(shù)據(jù)庫管理

    2023年04月17日
    瀏覽(19)
  • MySQL數(shù)據(jù)庫忘記密碼后,如何修改密碼

    MySQL數(shù)據(jù)庫忘記密碼后,如何修改密碼

    1、以管理員身份打開命令行 2、在命令行中進入MySQL的bin目錄所在文件夾 即:在命令行中輸入: 路徑查找如下: 命令行輸入命令: 3、跳過MySQL用戶驗證登錄數(shù)據(jù)庫 命令行輸入: 注意:輸入此命令之后,當(dāng)前的命令行就無法操作了,此時需要再打開一個新的命令行。(在這一步

    2024年02月04日
    瀏覽(98)
  • 達夢數(shù)據(jù)庫如何查看字符集

    ?0 表示 GB18030,1 表示 UTF-8,2 表示 EUC-KR select SF_GET_UNICODE_FLAG(); select ?UNICODE (); 字符集在安裝初始化庫的時候指定,設(shè)定后不可更改,請在安裝時按照需求設(shè)置好 后期如果想修改就只能重新初始庫! 注意中文字符的長度問題:數(shù)據(jù)庫初始化參數(shù)? LENGTH_IN_CHAR=0 ?時,unicode 編

    2023年04月09日
    瀏覽(24)
  • 【Navicat】怎么在Navicat新建連接、新建數(shù)據(jù)庫、導(dǎo)入數(shù)據(jù)庫

    【Navicat】怎么在Navicat新建連接、新建數(shù)據(jù)庫、導(dǎo)入數(shù)據(jù)庫

    新建一個MySQL連接:打開Navicat,點擊“ 左上角第一個圖標(biāo) -- MySQL ”。 其他的信息都是自動出現(xiàn)的,只需填寫 連接名和密碼 后點擊保存,就新建好了一個連接。 打開新建好的連接:點擊“Open Connection”打開連接。 出現(xiàn)綠色說明打開了數(shù)據(jù)庫的連接,然后單擊右鍵。 新建數(shù)

    2023年04月27日
    瀏覽(30)
  • 如何查看其他電腦的MYSQL數(shù)據(jù)庫 mysql查詢另一個ip數(shù)據(jù)庫

    文章標(biāo)簽 如何查看其他電腦的MYSQL數(shù)據(jù)庫mysql數(shù)據(jù)庫服務(wù)器MySQL 文章分類 MySQL數(shù)據(jù)庫 閱讀數(shù) 143 1.如何通過IP訪問MySQL數(shù)據(jù)庫 1.1 改表法 1.2 授權(quán)法 2.MySQL數(shù)據(jù)庫基本命令 2.1 基本命令 2.2 注釋 2.3 2.4 實踐操作 3 小結(jié) 1.1 改表法 如果不從遠程登陸,可以用 localhost 。這個時候

    2024年01月21日
    瀏覽(24)
  • 如何查看Oracle數(shù)據(jù)庫的端口列表Portlist?

    要在SQL/PLUS工具中查看Oracle數(shù)據(jù)庫的端口列表,可以執(zhí)行以下步驟: 在SQL/PLUS中使用系統(tǒng)管理員帳戶登錄到Oracle數(shù)據(jù)庫。 運行以下命令: 這將顯示數(shù)據(jù)庫中所有監(jiān)聽器使用的協(xié)議和端口。如果該命令返回端口號,則表示數(shù)據(jù)庫已配置為允許通過Web訪問。如果命令返回空值或錯

    2024年02月13日
    瀏覽(20)
  • Android 使用sqlcipher加密和解密數(shù)據(jù)庫(包括加密和解密已有的數(shù)據(jù)庫,還有如何查看數(shù)據(jù)庫教程)

    前言 我們知道Android系統(tǒng)有一個內(nèi)嵌的SQLite數(shù)據(jù)庫,并且提供了一整套的API用于對數(shù)據(jù)庫進行增刪改查操作,SQLite是一個輕量級的、跨平臺的、開源的嵌入式數(shù)據(jù)庫引擎,也是一個關(guān)系型的的使用SQL語句的數(shù)據(jù)庫引擎,讀寫效率高、資源消耗總量少、延遲時間少,使其成為移

    2024年02月06日
    瀏覽(22)
  • 【Android入門到項目實戰(zhàn)--4.8】—— 如何查看數(shù)據(jù)庫?(adb)

    【Android入門到項目實戰(zhàn)--4.8】—— 如何查看數(shù)據(jù)庫?(adb)

    目錄 什么是adb? 配置adb 使用adb 本文使用adb shell來查看數(shù)據(jù)庫。 ????????adb是Android SDK中自帶的一個調(diào)試工具,可以直接對連接在電腦上的手機或模擬器進行調(diào)試操作,它存放在sdk的platform-tools目錄里,如果想在命令行中使用,先把它的路徑配置到環(huán)境變量里。 ??????

    2024年02月15日
    瀏覽(23)

覺得文章有用就打賞一下文章作者

支付寶掃一掃打賞

博客贊助

微信掃一掃打賞

請作者喝杯咖啡吧~博客贊助

支付寶掃一掃領(lǐng)取紅包,優(yōu)惠每天領(lǐng)

二維碼1

領(lǐng)取紅包

二維碼2

領(lǐng)紅包