Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Security info not parsed ! #529

Open
xkostrna opened this issue Feb 13, 2025 · 2 comments
Open

Security info not parsed ! #529

xkostrna opened this issue Feb 13, 2025 · 2 comments

Comments

@xkostrna
Copy link

Detailed problem description

I've created a project in ETS6. This project contains secure device and this project is protected by password. Using your library I'm able to pass path to a project export and project password to an object which can then parse the export to Python. Like this:

knxproj: XKNXProj = XKNXProj(path="C:/..../myproject.knxproj", password="..")
data = knxproj.parse()

This is pretty good however there is very important information missing in the result of the parse method ! Missing information are:

  • DeviceAuthenticationCode
  • DeviceAuthenticationCodeHash
  • DeviceManagementPassword
  • DeviceManagementPasswordHash
  • ToolKey

Device which I've used for secure project is IP Interface Secure N 148/23 and this device has also passwords for it's bus interfaces.

How I found this:

  1. I've manually extracted project export using 7zip.
  2. I found another .zip file in the project called P-0267 so I've un-zipped it using project password hash (your function in xknxproject.zip.extractor -> _generate_ets6_zip_password).
  3. Inside P-0267 I've found file called 0.xml and there was the missing data listed above.

Question

Do you plan on adding any feature to add this secure info ? Maybe some typed dict called secure_info. Thank you very much !

@xkostrna
Copy link
Author

Secure device in ETS6

Image

Directory structure of unzipped project export

Image

content of 0.xml file

Image

@farmio
Copy link
Member

farmio commented Feb 13, 2025

Hi 👋!

Do you plan on adding any feature to add this secure info ?

This is currently not on my TODO-list. If you like to add it, feel free to do a PR! But I'd suggest to make it optional by some bool parameter passed eg. to the parse() method or somewhere else (like parse(include_secure_info=True))

May I ask what you'd need that info for?
Are you aware that this can be exported by ETS as a separate .knxkeys file that can also be used in xknx? See

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

No branches or pull requests

2 participants