locked
Null Dereference c# RRS feed

  • Question

  • Good Afternoon

    My curiosity is regarding a security warning I discloses a tool called fortifymyapp.com where they analyze and detect the debugged application vulnerabilities, specifically my partner is making contact with this tool, my concern is this tool throws me a security warning which is Null Dereference and is on the next page https://www.owasp.org/index.php/Null_Dereference ...... I do not understand because if so pointers if my application I'm using pointers to my development of my application in c # in wpf ..... Let me know how I can locate these pointers within the code or if the tool you use my partner is wrong .... Thanks for your help .... Greetings.


    • Edited by josecordero Tuesday, June 18, 2013 7:38 PM
    • Moved by Ego Jiang Wednesday, June 19, 2013 1:52 AM
    Tuesday, June 18, 2013 7:37 PM

Answers

  • He speaks of a variable reset method exists to a variable of type null for error I reset not null type variable, and give me some example on page cited above

    https://www.owasp.org/index.php/Null_Dereference

    First off - that page is referring to C and C++, NOT C#.  Things are a bit different in C#.  From that page: "Languages: C, C++, Assembly"

    Nothing on that page refers to a "variable reset method" - not sure what you're after here...


    Reed Copsey, Jr. - http://reedcopsey.com
    If a post answers your question, please click "Mark As Answer" on that post and "Mark as Helpful".

    Tuesday, June 18, 2013 10:08 PM

All replies

  • In C#, the equivelent would be something like:

    SomeClass myInstance = null; // Set this to null somehow
    
    myInstance.Foo(); // Try to call a method on a null variable, and you'll get NullReferenceException



    Reed Copsey, Jr. - http://reedcopsey.com
    If a post answers your question, please click "Mark As Answer" on that post and "Mark as Helpful".

    Tuesday, June 18, 2013 7:47 PM
  • He speaks of a variable reset method exists to a variable of type null for error I reset not null type variable, and give me some example on page cited above

    https://www.owasp.org/index.php/Null_Dereference

    Tuesday, June 18, 2013 9:18 PM
  • He speaks of a variable reset method exists to a variable of type null for error I reset not null type variable, and give me some example on page cited above

    https://www.owasp.org/index.php/Null_Dereference

    First off - that page is referring to C and C++, NOT C#.  Things are a bit different in C#.  From that page: "Languages: C, C++, Assembly"

    Nothing on that page refers to a "variable reset method" - not sure what you're after here...


    Reed Copsey, Jr. - http://reedcopsey.com
    If a post answers your question, please click "Mark As Answer" on that post and "Mark as Helpful".

    Tuesday, June 18, 2013 10:08 PM
  • Hi josecordero,

    From your post, I don't think this issue is related to MSBuild. I am moving this thread to Where is the forum for which can help you moving this case to related forum.

    Best regards, 


    Ego [MSFT]
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Wednesday, June 19, 2013 1:51 AM