ÆÄÀ̽ã - BasicAuth.

¾öû³ª°Ô °£´ÜÇÑ HTTP ±âº» ÀÎÁõ ±¸Çö
Áö±Ý ´Ù¿î·Îµå

ÆÄÀ̽ã - BasicAuth. ¼øÀ§ ¹× ¿ä¾à

±¤°í

  • Rating:
  • ƯÇã:
  • Other/Proprietary Li...
  • °¡°Ý:
  • FREE
  • °Ô½ÃÀÚ À̸§:
  • Randall Degges
  • °Ô½ÃÀÚ À¥»çÀÌÆ®:
  • http://github.com/comradeb14ck/

ÆÄÀ̽ã - BasicAuth. ű×


ÆÄÀ̽ã - BasicAuth. ¼³¸í

Python-BasicAuth´Â Á×Àº °£´ÜÇÑ HTTP ±âº» ÀÎÁõ ¿£ÄÚ´õ ¹× µðÄÚ´õÀÔ´Ï´Ù. ¿Ö¿ä? HTTP¸¦ ½±°Ô µå·ÓÇؾßÇϱ⠶§¹®¿¡. ±× ÀÌÀ¯´Â``python-basicauth``¸¦ ¼³Ä¡ÇÏ°í``pip ¼³Ä¡ basicAuth````À» ¼³Ä¡ÇÏ°í ÃֽŠ¹öÀüÀ» outpount.ustageto¸¦ ¼³Ä¡ÇÕ´Ï´Ù.```python >>> basicauth¿¡¼­ ÀÎÄÚµù µÈ ±âº» ÀÎÁõ ¹®ÀÚ¿­À» »ý¼ºÇÕ´Ï´Ù °¡Á® ¿À±â >>> »ç¿ëÀÚ À̸§, ¾ÏÈ£ = 'rdegges', 'omghax !!!'>>> encoded_str = encode (»ç¿ëÀÚ À̸§, ¾ÏÈ£) >>> Àμâ encoded_str'basic cmrlz2dlczpvbwdoyxglmjelmjelmje = '```````````ÀÎÄÚµù µÈ ±âº» ÀÎÁõ ¹®ÀÚ¿­ :```python >>> basicauth °¡Á® ¿À±â µðÄڵ忡¼­ >>> À§ÀÇ ¿¹¿¡¼­ ±âº» cmrlz2dlczpvbwdoyxglmjelmjelmje = '#. >>> username, password = decode (encodeed_str) >>> Àμâ (»ç¿ëÀÚ À̸§, ¾ÏÈ£) (' rdegges ','omghax !!! ')```````python >>> basicauth °¡Á® ¿À±â >>>¿¡¼­````python >>> À§ÀÇ ¿¹Á¦¿¡¼­. >>> »ç¿ëÀÚ À̸§, ¾ÏÈ£ = µðÄÚµå (ENCODED_STR) >>> Àμâ (»ç¿ëÀÚ À̸§, ¾ÏÈ£) ( 'rdegges', 'omghax !!!)```````python >>> BasicAuth °¡Á® ¿À±â µðÄڵ忡¼­, DecodeError >>> Enco. ded_str = 'lol omg cmrlz2dlczpvbwdoyxglmjelmjelmje ='# À߸øµÈ Çؽà = 'À߸øµÈ ÇؽÃ. >>> username, password = decode (encoded_str) ÃßÀû (°¡Àå ÃÖ±ÙÀÇ È£Ãâ ¸¶Áö¸·) : ""ÆÄÀÏ "basicauth / __ init__.py"ÆÄÀÏ "" , 49 Çà, µðÄڵ忡¼­ DecodeErrorBasicauth.decodeError````testswant°¡ Å×½ºÆ®¸¦ ½ÇÇà ÇϽðڽÀ´Ï±î? ¹®Á¦ ¾øÀ½ :```bash $ git clone git : //github.com/rdegges/python-basicauth.gits/python-basicauth.git$ cd python-basicauth $ python setup.py °³¹ß ... $ pip install -r ¿ä±¸ »çÇ× # inst test Å×½ºÆ® ÀÇÁ¸¼º. $ nosetests .............---------------------------------------------------------------- ------------------------------------- 0.166sokProductÀÇ È¨ÆäÀÌÁö¿¡¼­ 13 °³ÀÇ Å×½ºÆ®¸¦ ¼öÇàÇß½À´Ï´Ù


ÆÄÀ̽ã - BasicAuth. °ü·Ã ¼ÒÇÁÆ®¿þ¾î

iterpipes3.

½©°ú °°Àº ±¸¹®À» »ç¿ëÇÏ¿© ½© ÆÄÀÌÇÁ ¶óÀÎÀ» ½ÇÇàÇÏ´Â ¶óÀ̺귯¸® ...

61

´Ù¿î·Îµå