Security

APX1102 – SUSER_SNAME() and SYSTEM_USER

Description:

This rule evaluates the T-SQL script for using SUSER_SNAME() and SYSTEM_USER.

Consider using ORIGINAL_LOGIN() instead to improve security.

For more information visit

https://stackoverflow.com/questions/37963595/is-suser-sname-less-secure-then-original-login

Example script:

Message:

Column Login contains SUSER_SNAME() or SYSTEM_USER. Consider ORIGINAL_LOGIN() instead

SQLShack

SQLShack

SQL Shack was created as a community service from ApexSQL, with the goal to share SQL Server knowledge through articles written by SQL Server professionals and community members
SQLShack

Latest posts by SQLShack (see all)