Working with Binary Data in Python 3




Working with Binary Data in Python 3

Learn how to work with binary data using Python 3. Everything in a computer is binary and bytes under the hood, so it is critical to understand how to work with data at this raw level.

Knowing how to manipulate binary data at and byte streams is an essential skill for any type of programming you do with Python from web developers to data scientists to game developers to security analysts and engineers, malware reverse engineers, and penetration testers

Some of the things you will learn include:

  • Reading write bytes to buffer streams and disk which is useful for working with any kind of binary file or network communication

  • Formatting output of bytes so you can view it as hexadecimal or even binary format.

  • Converting between Python objects and raw bytes which is useful for storing objects to disk or loading up binary data that was intended for a different computer system

  • Encoding and decoding bytes which lets you switch between raw bytes that you can store and transfer and usable objects in Python. For example, creating a save game file or transmitting data over the network.

  • Packing and unpacking structs; For example, creating a TCP/IP packet header or extracting data from proprietary file formats.

  • Performing bitwise operation like AND, OR, XOR, and ones copmlement which is useful for a variety of tasks like network masking and cryptography.

Course syllabus

Intro

  • Course overview

Basics of bytes

  • Bytes type

  • Bytearray type

  • BytesIO class

  • Formatting output

Bitwise operations

  • AND

  • OR

  • XOR

  • Ones complement

  • Bit shifting

Conversion

  • Integers <-> Bytes

  • Binary strings

  • Hexadecimal strings

Working with files

  • Read and write bytes

  • Seek position

  • Get metadata about a file

Struct packing

  • What is struct packing?

  • Struct packing

  • Struct unpacking

Encoding

  • ASCII

  • UTF-8

  • Base64

Learn to read, write, manipulate and operate on bits and bytes

Url: View Details

What you will learn
  • Work with raw bytes in Python 3
  • Read and write binary files
  • Formatting binary output

Rating: 4.65

Level: Intermediate Level

Duration: 1.5 hours

Instructor: John Leon


Courses By:   0-9  A  B  C  D  E  F  G  H  I  J  K  L  M  N  O  P  Q  R  S  T  U  V  W  X  Y  Z 

About US

The display of third-party trademarks and trade names on this site does not necessarily indicate any affiliation or endorsement of hugecourses.com.


© 2021 hugecourses.com. All rights reserved.
View Sitemap