How to add the password protected file in mvc archiecture using htaccess

Hi I can set the password protected file in normal way , but it doesnt suit for the mvc archieture . any one suggest a solution to it.

i used like this in normal

AuthType Basic
AuthName "My Protected Area"
AuthUserFile c:/wamp/www/protected/.htpasswd

<Files "check.php">
  Require valid-user
</Files>

how do i set filename in framework?

There isn’t a simple answer. Since URLs are now routed by your application, security will also need to be implemented by your application. After you match a URL to a controller, you’ll then need to test if that controller allows anonymous access, or if it requires an authenticated user, as well as whether authenticated users require any special credentials, such as admin.