EricZimmerman / evtx

C# based evtx parser with lots of extras
MIT License
272 stars 59 forks source link

avoid CS0104 error on linux, make namespaces unabiguous #232

Closed fwacrtnty closed 11 months ago

fwacrtnty commented 11 months ago

Description

When EvtxECmd is cloned to linux and build with net6 you get the following errors:

/home/flow/sources/evtx/EvtxECmd/Program.cs(558,30): error CS0104: "EventLog" ist ein mehrdeutiger Verweis zwischen "System.Diagnostics.EventLog" und "evtx.EventLog". [/home/flow/sources/evtx/EvtxECmd/EvtxECmd.csproj]
/home/flow/sources/evtx/EvtxECmd/Program.cs(565,59): error CS0104: "EventLog" ist ein mehrdeutiger Verweis zwischen "System.Diagnostics.EventLog" und "evtx.EventLog". [/home/flow/sources/evtx/EvtxECmd/EvtxECmd.csproj]
/home/flow/sources/evtx/EvtxECmd/Program.cs(637,13): error CS0104: "EventLog" ist ein mehrdeutiger Verweis zwischen "System.Diagnostics.EventLog" und "evtx.EventLog". [/home/flow/sources/evtx/EvtxECmd/EvtxECmd.csproj]
/home/flow/sources/evtx/EvtxECmd/Program.cs(652,21): error CS0104: "EventLog" ist ein mehrdeutiger Verweis zwischen "System.Diagnostics.EventLog" und "evtx.EventLog". [/home/flow/sources/evtx/EvtxECmd/EvtxECmd.csproj]
/home/flow/sources/evtx/EvtxECmd/Program.cs(722,21): error CS0104: "EventLog" ist ein mehrdeutiger Verweis zwischen "System.Diagnostics.EventLog" und "evtx.EventLog". [/home/flow/sources/evtx/EvtxECmd/EvtxECmd.csproj]
/home/flow/sources/evtx/EvtxECmd/Program.cs(1038,17): error CS0104: "EventLog" ist ein mehrdeutiger Verweis zwischen "System.Diagnostics.EventLog" und "evtx.EventLog". [/home/flow/sources/evtx/EvtxECmd/EvtxECmd.csproj]
/home/flow/sources/evtx/EvtxECmd/Program.cs(1039,31): error CS0104: "EventLog" ist ein mehrdeutiger Verweis zwischen "System.Diagnostics.EventLog" und "evtx.EventLog". [/home/flow/sources/evtx/EvtxECmd/EvtxECmd.csproj]

I changed the listed places and made the namspace to be used unabigiuous, now it compiles on linux like charm.

Checklist:

Note: i have not touched any Maps

Please replace every instance of [ ] with [X] OR click on the checkboxes after you submit your PR

Thank you for your submission and for contributing to the DFIR community!

EricZimmerman commented 11 months ago

seems good to me