MS-SQL > ¾ÏÈ£È/º¹È£È - EncryptByPassPhrase() / DecryptByPassPhrase() µî·ÏÀÏ : 2017-07-03 19:48 Á¶È¸¼ö : 52,427±âÁ¸¿¡ ±¸ÃàÇسõÀº DB¸¦ ¹ÙÅÁÀ¸·Î Å×À̺íÀÇ Çʵ带 ¾ÏÈ£È ÇÏ°íÀÚ ÇÒ¶§¸¦ ¿¹·Î µç´Ù.
Å×À̺í¸í : T_MEMBER ±âÁ¸ Çʵå¸í : F_PHONE »õ·Î¿î Çʵå¸í : F_PHONE_TEMP 2. »õ·Î¿î Çʵ带 »ý¼ºÇÑ´Ù. ¿©±â¼´Â F_PHONE_TEMP ¶ó´Â Æú´õ¸¦ »ý¼ºÇß´Ù. 3. ¾ÏÈ£È Äڵ尪Àº ´ÙÀ½Áß Çϳª¸¦ ¼±ÅÃÇϵµ·Ï ÇÑ´Ù. MD2, MD4, MD5SHA, SHA1 ¿©±â¼´Â 'MD4'¸¦ »ç¿ëÇϵµ·Ï ÇÏ°Ú´Ù. -- ¾ÏÈ£È UPDATE T_MEMBER SET F_PHONE_TEMP = EncryptByPassPhrase('MD4',F_PHONE) -- º¹È£È È®ÀÎ Select F_PHONE, F_PHONE_TEMP, Convert(varchar(Max),DecryptByPassPhrase('MD4',F_PHONE_TEMP)) from T_MEMBER 4. F_PHONE ÇÊµå »èÁ¦ÇÏ°í F_PHONE_TEMP Çʵå¸íÀ» F_PHONE ·Î º¯°æ
|