A thread acquiring a lock on an object that can be accessed across application domain boundaries runs the risk of being blocked by another thread in a different application domain. Objects that can be accessed across application domain boundaries are said to have weak identity. Types with weak identity are:

Noncompliant Code Example

public class Sample
{
    string myString = "foo";

    public void Go()
    {
        lock (myString) { } // Noncompliant
    }
}

Compliant Solution

public class Sample
{
    private readonly static string thisLock = new object();

    public void Go()
    {
        lock (thisLock) { }
    }
}