Skip to main content

.NET viewstate decoder

Project description

A small Python 3 library for decoding .NET viewstate. Can be used in various scraping scenarios.

https://travis-ci.org/yuvadm/viewstate.svg?branch=master

Install

$ pip install viewstate

Usage

The Viewstate decoder accepts Base64 encoded .NET viewstate data and returns the decoded output in the form of plain Python objects.

There are two main ways to use this package. First, it can be used as an imported library with the following typical use case:

from viewstate import ViewState
vs = ViewState(base64EncodedViewState)
decoded_state = vs.decode()

It is also possible to feed the raw bytes directly:

vs = ViewState(raw=b'\xff\x01....')

Alternatively, the library can be used via command line by directly executing the module:

$ cat data.base64 | python -m viewstate

Which will pretty-print the decoded data structure.

Development

$ pytest

References

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

viewstate-0.3.0.tar.gz (4.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

viewstate-0.3.0-py2.py3-none-any.whl (6.8 kB view details)

Uploaded Python 2Python 3

File details

Details for the file viewstate-0.3.0.tar.gz.

File metadata

  • Download URL: viewstate-0.3.0.tar.gz
  • Upload date:
  • Size: 4.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for viewstate-0.3.0.tar.gz
Algorithm Hash digest
SHA256 3e680727bdf8660fe3cff3fdeb8ca769108ccc02a612487ae7c31df75659f761
MD5 ba245650169dbace7610773c7f2c8d24
BLAKE2b-256 2299696efad80cc92b088d2146e4861f5ad8c617e10dbd0fbbb3238516709c73

See more details on using hashes here.

File details

Details for the file viewstate-0.3.0-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for viewstate-0.3.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 97f6d97ecfddf4485475c9cb13bed84b2702888eb1c8cdee833f62dbca9af16f
MD5 639eee3a654e678582c0297504baca07
BLAKE2b-256 a2d701079607e3f9285d247fffb9e4bf8df2db893716f9e8b08546e2d544c0d5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page