If I've read that correctly, and there's a chance I haven't, not only can an agency not ask you for your SSN under most conditions but you can sue the agency for asking but not the individual who asked.
So the flatfoots who get tasked with asking are immune but the LAPD isn't.
However, what if you point out that it's illegal to ask you, they insist, you refuse and get arrested, can you then sue the officer because you pointed out that it is illegal to ask?