Windows Scokect Error codes:
http://msdn.microsoft.com/en-us/library/ms740668(VS.85).aspx
http://www.sockets.com/err_lst1.htm
Windows Socket for newbie:
http://tangentsoft.net/wskfaq/newbie.html
The complete tutorial(newbie/intermediate/advanced) address is:
http://tangentsoft.net/wskfaq/
You should read articles in these two sections(for mechanism):
Windows Developmen/Security:
http://msdn.microsoft.com/en-us/library/ee663293(v=VS.85).aspx
Security Technical Articles [under Windows Developmen/Security/Security Technical Articles , 1) Security (General), 2) Cryptography, 3)Smart Card)]:
http://msdn.microsoft.com/en-us/library/ff803128.aspx
Functions for Windows security(Authentication, Security Management etc):
http://msdn.microsoft.com/en-us/library/ee663293%28v=VS.85%29.aspx
[For Information Update]
Microsoft Security Development Lifecycle(SDL)
Compare of secure/insecure functions:
http://msdn.microsoft.com/en-us/library/bb288454.aspx
Windows Data Protection:
http://msdn.microsoft.com/en-us/library/ms995355.aspx