Perforce Public Knowledge Base - Authentication Triggers: Troubleshooting
× PRODUCTS SOLUTIONS CUSTOMERS LEARN SUPPORT
Downloads Company Partners Careers Contact Free Trials
Menu Search
Perforce
Reset Search
 

 

Article

Authentication Triggers: Troubleshooting

« Go Back

Information

 
Problem
Since authentication triggers can limit all access, including the super user's, it is possible to completely lock all access to the server. This article describes how to restore access to the Perforce server should this occur.
 
Solution

Typo or Other Trigger Table Error

A mistake in the path to your trigger or the arguments you are passing to your trigger are the most common errors. Starting with server versions 2005.2 and later, Perforce administrators can replace the broken trigger entry using a server command:
  1. Stop the Perforce server or service.
     
  2. Enter the command:
    p4d -r $P4ROOT -xf 18362 "echo 0"

    or on Windows 7:

    p4d -r . -xf 18362 subst
    

    which will display

    External authentication trigger replaced successfully.
    
    This replaces the command in the "auth-check" trigger table entry with "echo 0" (zero), which always returns true. For example, if your original table entry was:
    my_check auth-check auth "C:wrong_path_tomy_command.pl %user%"
    After running the p4d -xf command it is:
    my_check auth-check auth "echo 0"
    

    or

    my_check auth-check auth subst
  3. Since this trigger means that ANY password is accepted, set P4PORT to "localhost:{port number}" before restarting. This limits connections to those local to the Perforce server.
     
  4. Restart the Perforce server or service.
You should now be able to log into Perforce. Fix the trigger table entry, reset P4PORT to your original setting, and restart the server or service.

When Replacing the Trigger Table Entry Fails

If you have just replaced the trigger with the p4d -xf command and you still cannot log in, try it again once or twice. You might see something like this example output:
p4 login 
Enter password: 
Password invalid. 
'auth' validation failed: 
write: echo: Broken pipe 

p4 login 
Enter password: 
Password invalid. 
'auth' validation failed: 
write: echo: Broken pipe 

p4 login 
Enter password: 
User user1 logged in. 

The Trigger Works, But The Correct User and Password Fails

  • If you have confirmed that you are using the correct name and password with a working Active Directory trigger, try adding the domain prior to the user name. For example:
    p4 login DOMAIN/user_name
  • For Perforce Server versions prior to 2011.1, confirm that the password for the user does not exceed 16 characters in length. While Perforce will accept a longer password, it will be truncated to 16 characters.

For more information on triggers, see Triggers in the Perforce System Administrator's Guide.

Related Links
Debugging Triggers (KB Article)
 

Feedback

 

Was this article helpful?


   

Feedback

Please tell us how we can make this article more useful.

Characters Remaining: 255