# 113 - Pentesting Ident {{#include ../banners/hacktricks-training.md}} ## Basic Information **Ident Protocol** का उपयोग **Internet** पर एक विशेष उपयोगकर्ता के साथ **TCP connection** को जोड़ने के लिए किया जाता है। मूल रूप से **network management** और **security** में सहायता के लिए डिज़ाइन किया गया, यह एक सर्वर को पोर्ट 113 पर एक क्लाइंट से जानकारी मांगने की अनुमति देकर काम करता है ताकि एक विशेष TCP कनेक्शन के उपयोगकर्ता के बारे में जानकारी प्राप्त की जा सके। हालांकि, आधुनिक गोपनीयता चिंताओं और दुरुपयोग की संभावनाओं के कारण, इसका उपयोग कम हो गया है क्योंकि यह अनजाने में उपयोगकर्ता की जानकारी को अनधिकृत पक्षों के लिए प्रकट कर सकता है। इन जोखिमों को कम करने के लिए, एन्क्रिप्टेड कनेक्शनों और सख्त पहुंच नियंत्रण जैसे उन्नत सुरक्षा उपायों की सिफारिश की जाती है। **Default port:** 113 ``` PORT STATE SERVICE 113/tcp open ident ``` ## **Enumeration** ### **Manual - Get user/Identify the service** यदि एक मशीन सेवा ident और samba (445) चला रही है और आप पोर्ट 43218 का उपयोग करके samba से जुड़े हैं। आप यह जान सकते हैं कि कौन सा उपयोगकर्ता samba सेवा चला रहा है: ![](<../images/image (843).png>) यदि आप सेवा से कनेक्ट करते समय केवल एंटर दबाते हैं: ![](<../images/image (159).png>) अन्य त्रुटियाँ: ![](<../images/image (359).png>) ### Nmap डिफ़ॉल्ट रूप से (\`-sC\`\`) nmap हर चल रहे पोर्ट के हर उपयोगकर्ता की पहचान करेगा: ``` PORT STATE SERVICE VERSION 22/tcp open ssh OpenSSH 4.3p2 Debian 9 (protocol 2.0) |_auth-owners: root | ssh-hostkey: | 1024 88:23:98:0d:9d:8a:20:59:35:b8:14:12:14:d5:d0:44 (DSA) |_ 2048 6b:5d:04:71:76:78:56:96:56:92:a8:02:30:73:ee:fa (RSA) 113/tcp open ident |_auth-owners: identd 139/tcp open netbios-ssn Samba smbd 3.X - 4.X (workgroup: LOCAL) |_auth-owners: root 445/tcp open netbios-ssn Samba smbd 3.0.24 (workgroup: LOCAL) |_auth-owners: root ``` ### Ident-user-enum [**Ident-user-enum**](https://github.com/pentestmonkey/ident-user-enum) एक सरल PERL स्क्रिप्ट है जो ident सेवा (113/TCP) को क्वेरी करने के लिए है ताकि यह निर्धारित किया जा सके कि लक्षित प्रणाली के प्रत्येक TCP पोर्ट पर सुनने वाली प्रक्रिया का मालिक कौन है। एकत्रित उपयोगकर्ता नामों की सूची का उपयोग अन्य नेटवर्क सेवाओं पर पासवर्ड अनुमान लगाने के हमलों के लिए किया जा सकता है। इसे `apt install ident-user-enum` के साथ स्थापित किया जा सकता है। ``` root@kali:/opt/local/recon/192.168.1.100# ident-user-enum 192.168.1.100 22 113 139 445 ident-user-enum v1.0 ( http://pentestmonkey.net/tools/ident-user-enum ) 192.168.1.100:22 root 192.168.1.100:113 identd 192.168.1.100:139 root 192.168.1.100:445 root ``` ### Shodan - `oident` ## Files identd.conf ## HackTricks Automatic Commands ``` Protocol_Name: Ident #Protocol Abbreviation if there is one. Port_Number: 113 #Comma separated if there is more than one. Protocol_Description: Identification Protocol #Protocol Abbreviation Spelled out Entry_1: Name: Notes Description: Notes for Ident Note: | The Ident Protocol is used over the Internet to associate a TCP connection with a specific user. Originally designed to aid in network management and security, it operates by allowing a server to query a client on port 113 to request information about the user of a particular TCP connection. https://book.hacktricks.wiki/en/network-services-pentesting/113-pentesting-ident.html Entry_2: Name: Enum Users Description: Enumerate Users Note: apt install ident-user-enum ident-user-enum {IP} 22 23 139 445 (try all open ports) ``` {{#include ../banners/hacktricks-training.md}}