Skip to content

Full Migration pysap from Python 2.7 to Python 3#84

Open
vah13 wants to merge 1 commit intoOWASP:masterfrom
redrays-io:master
Open

Full Migration pysap from Python 2.7 to Python 3#84
vah13 wants to merge 1 commit intoOWASP:masterfrom
redrays-io:master

Conversation

@vah13
Copy link
Contributor

@vah13 vah13 commented Mar 26, 2026

Full migration of the pysap library to Python 3 with support for Python 3.9 through 3.12 on Linux, macOS and Windows.

Core changes:

  • Replaced deprecated Python 2 imports (cStringIO, SocketServer, Queue)
  • Ported the pysapcompress C extension to the Python 3 module API
  • Fixed string vs bytes handling across all SAP protocol modules
  • Updated the cryptographic routines for proper bytes operations
  • Resolved scapy 2.7 compatibility issues with duplicate field names

Infrastructure:

  • Modernized the CI/CD pipeline to test against Python 3.9-3.12
  • Updated all dependency versions for Python 3 compatibility
  • Adapted the full test suite to work with Python 3 semantics

Full migration of the pysap library to Python 3 with support for Python 3.9 through 3.12 on Linux, macOS and Windows.

Core changes:
- Replaced deprecated Python 2 imports (cStringIO, SocketServer, Queue)
- Ported the pysapcompress C extension to the Python 3 module API
- Fixed string vs bytes handling across all SAP protocol modules
- Updated the cryptographic routines for proper bytes operations
- Resolved scapy 2.7 compatibility issues with duplicate field names

Infrastructure:
- Modernized the CI/CD pipeline to test against Python 3.9-3.12
- Updated all dependency versions for Python 3 compatibility
- Adapted the full test suite to work with Python 3 semantics
Copy link
Contributor

@codeHorse87 codeHorse87 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @vah13 thanks a lot for the PR which looks very promissing. I'm currently quite occupied to conduct a comprehensive review, as well as I'm missing some permission on the repo atm.
I'm not sure if @martingalloar meanwhile can support with the code review meanwhile? I'll do my very best to create a test setup and check with a SAP testing environment.

@vah13
Copy link
Contributor Author

vah13 commented Mar 26, 2026

Hello, I can share with you the demo environment of SAP S4 2025 for testing.

@kloris
Copy link

kloris commented Mar 26, 2026

@vah13, thanks! Currently totally occupied but when there is some time later I will definitely test with it. Long awaited this thing so thanks for doing this

@JonathanStross
Copy link

@codeHorse87 - connect on this? Maybe I can support

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants