본문 바로가기

Sysops Notepad

검색하기
Sysops Notepad
프로필사진 sysops

  • 분류 전체보기 (188)
    • TIP (4)
    • IT (8)
    • 업무 (176)
      • sys (63)
      • dev (21)
      • etc (92)
    • 주식일기 (0)
Guestbook
Notice
Recent Posts
Recent Comments
Link
«   2025/07   »
일 월 화 수 목 금 토
1 2 3 4 5
6 7 8 9 10 11 12
13 14 15 16 17 18 19
20 21 22 23 24 25 26
27 28 29 30 31
Tags
  • Shell
  • rsyslog
  • GNOME
  • bash
  • 파이썬
  • 빅데이터
  • syslog
  • JSON
  • C
  • Chrome
  • Kubernetes
  • 크롬
  • 디렉토리
  • docker
  • Python
  • zabbix
  • Elk
  • RHEL
  • centos 7.5
  • PostgreSQL
  • Audit Log
  • Linux
  • 서울시민카드
  • log
  • audit
  • K8S
  • Elasticsearch
  • CentOS
  • yum
  • GPU
more
Archives
Today
Total
관리 메뉴
  • 글쓰기
  • 방명록
  • RSS
  • 관리

목록base64 (1)

Sysops Notepad

[Python] base64 인코딩/디코팅 하는법

import base64 def stringToBase64(a): return base64.b64encode(a.encode('utf-8')) def base64ToString(b): return base64.b64decode(b).decode('utf-8') def fileToBase64(filepath): fp = open(filepath, "rb") data = fp.read() fp.close() return base64.b64encode(data).decode('utf-8')

업무/dev 2019. 2. 15. 17:43
Prev 1 Next

Blog is powered by kakao / Designed by Tistory

티스토리툴바