Git Product home page Git Product logo

linkedin2username's People

Contributors

0xbc avatar 0xflotus avatar c0axx avatar coj337 avatar id3s3c avatar ihack4falafel avatar initstring avatar knavesec avatar nimmicus avatar vtasio avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

linkedin2username's Issues

Showing Error -[*] Using version 0.20, which is the latest on GitHub. [!] LinkedIn doesn't like something about this login. Maybe you're being sneaky on a VPN or something. You may get an email with a verification token. You can ignore the email. Log in from a web browser and try again.

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
Please provide the command as you ran it, omitting the target company name if necessary and of course your username and password.

Verify Expected Results
Have you verified that you can access the company page via the web UI, and that the expected amount of contacts are visible using your login?

Additional context
Do you have any type of special setup? Web proxy, two-factor LI authentication, etc.

[!] Could not find that company name

Hi @initstring

Testing this out and I keep getting the above error, irrespective of the company name used (even tried uber-com as a test).

Script output is as follows,

[*] Using version 0.10, which is the latest on Gitlab.

[*] Successfully logged in.

[!] Could not find that company name. Please double-check LinkedIn and try again.

Cannot login with valid credentials

the following error is received upon logging in with valid and working credentials

"Some unknown error logging in. If this persists, please open an issue on github."

Tool doesn't work well with "compound" names

Describe the bug
Output is messed up when you use the tool on employees with compound names separated with an - (eg. Jean-Pierre)
The tool is outputing 2 results for one target:
[email protected] & [email protected]

To Reproduce
Use the tool on a French company for example, where compound names are really common.

Verify Expected Results
Expected result may vary depending on the companies, could be the following :
[email protected]
[email protected]
[email protected]

DEBUG INFO: LOCATION: /settings RESPONSE TEXT:

I was told this when I tried using this script in CMD.

[!] Some unknown redirection occurred. If this persists, please open an issue and include the info below:
DEBUG INFO:
LOCATION: /settings
RESPONSE TEXT:

Update version check

Since migrating to GitHub, need to remove the GitLab-specific version checking.

Need to implement a similar one for GitHub.

Need to ensure whatever I do doesn't break the old versions pulled from GL

Improve README

The README is pretty verbose, and could use with a screenshot or two. I should condense it and try to make it look a bit nicer.

[REQUEST] Add occupation to the list

Hello

I love this tool, but I feel like I am missing crucial additional information about the scraped targets.... Their occupation in the company.
Can you add this function to the script.
I'm a noob in python so I won't be able to do it myself.

Edit: the time a person has already been employed is also of interest

Thanks in advance.

302

Always reminds me of this 302 error, do you know how to fix it?

[*] Using version 0.18, which is the latest on GitHub.

[!] Some unknown redirection occurred. If this persists, please open an issue on github.

JSONDecodeErrors

Describe the bug
I've used this tool without issue for a few years now and it's been extremely helpful (thank you!), but over the last few months it's been useless. It fails out every time I attempt to run it with "JSONDecodeError"

image

To Reproduce
Literally just run the program. Doesn't seem to matter which company I try to pull or how much data, it fails to decode the JSON.

python3 linkedin2username.py -u <linkedin_email> -n 'domain.com' -c 'companyinc'

Verify Expected Results
Yes

Additional context
No, I've even tried it in a docker container with previous versions of Python.

Cant login

running this : python3 linkedin2username.py -u ****@gmail.com -c uber-com -p *****

always return this :
You've been returned to a login page. Check your username and password and try again.

All searches result in "Unknown Redirection" message

Describe the bug
I've noticed over the past few weeks that any company search results in an error "Some unknown redirection occurred.".

To Reproduce
Command: ./linkedin2username.py -c <COMPANY> -u <USER-EMAIL>

Verify Expected Results
I logged into the LinkedIn account I use for this and verified the company page is accessible and I can view employees. I have also executed the tool against prior client companies where the tool had previously produced the expected output and I now receive the same error as above ("Some unknown redirection occurred").

Additional context
No special setup.

Error Prompting to Login to Web Gui

Describe the bug
Attempting to run a scan against a company, with these arguments:
python linkedin2username.py -u [email protected] -c companyname

The script prompts for my PW which I enter and it accepts however I continue to get the error below
LinkedIn has a message for you that you need to address. Please log in using a web browser first, and then come back and try again.

Have closed the shell, logged in on the web browser > accepted my MFA sign in request and it continues happening.
Have tried with different company names.
Have typed pw incorrectly to verify that a different error comes up when intentionally wrong.

To Reproduce
Run the script with arguements above.

Verify Expected Results
Have you verified that you can access the company page via the web UI, and that the expected amount of contacts are visible using your login? Yes. Have been manually creating a user list as I can't get my scripts working rofl
2023-05-18 16_23_55-kali-linux-2022 1-vmware-amd64 - VMware Workstation

Additional context
Do you have any type of special setup? No special setup - simply using this script on a kali VM on my windows host machine.

unable to login in LinkedIn

When I enter my credentials see the following result:

[-] LinkedIn has a message for you that you need to address.
[*] Please log in using a web browser first, and then come back and try again.
[-] Session could not be established.

I then open LinkedIn in my browser and see no message. I log out and back in and get the same result. I log in on other browsers on my machine, and get the same result.

I do have 2FA enabled, but I have it set to an authenticator app which generates a code.

I am running on an Intel MacBook Pro, Mac OS 13.4.1 (c) (22F770820d), Python 3.10.12 from homebrew, and I had to modify the requirements.txt to "psycopg2-binary==2.9.6" in order to be able to install. I plan on testing this on my M2 machine tomorrow to see if there is any difference.

Please let me know if there are any additional details needed.

2FA will be supported in the future?

Can't log in

Hello,

I've been getting this anytime I'm trying to log in. The manual is not at all very clear how to run the commands. I assume when I run python3 linkedin2username.py --username xxxxxxx -c xxxxx I put my own username and then when asked for the password I put my password. Well, I've been getting the following:

Password:

[*] Using version 0.16, which is the latest on GitHub.

[!] Some unknown error logging in. If this persists,please open an issue on github.

Any clues?

All help is appreciated!

Some account notification

Hi,

When I run the tool i get the following message:

[*] Using version 0.21, which is the latest on GitHub.

[!] LinkedIn has some account notification for you to check. Please log in first via the web and clear that.

I have logged into via the web and there are no messages, notifications, new connections or other obvious alerts?

Linkedin2username not working

Describe the bug
Consistently get this message when trying to run the tool:

[!] LinkedIn has some account notification for you to check. Please log in first via the web and clear that.

No issues in LinkedIn account to clear.

To Reproduce
Happens every time I try to run script.

Verify Expected Results
Yes

Additional context
None

artifically low output

shows only 25 results of over 16k results using linkedin by web browser shows the 16k+ plus users

[+] Starting search....

[+] Company has 16050 profiles to check. Some may be anonymous.
[+] Setting search to 643 loops of 25 results each.

[+] OK, looking for results on loop numer 1
[+] Added 25 new names.
[+] OK, looking for results on loop numer 2
[+] We have hit the end of the road! Moving on...

All done! Check out your lovely new files.

[!] Some unknown redirection occurred

Describe the bug
A clear and concise description of what the bug is.
I execute the code python3 linkedin2username.py -c sos -g -u [email protected]
-n "uber.com" -p mypassord

To Reproduce
Please provide the command as you ran it, omitting the target company name if necessary and of course your username and password.
I tried to proof the first example but allways get the same error message:
[!] Some unknown redirection occurred. If this persists, please open an issue on github.

Verify Expected Results
Have you verified that you can access the company page via the web UI, and that the expected amount of contacts are visible using your login?
yes.

Additional context
Do you have any type of special setup? Web proxy, two-factor LI authentication, etc.
No.

list index out of range

I'm getting this when running against a specific client:

[+] Successfully logged in.

Traceback (most recent call last):

File "linkedin2username.py", line 235, in
main()

File "linkedin2username.py", line 228, in main
companyID = get_company_info(company, session)

File "linkedin2username.py", line 99, in get_company_info
foundDesc = re.findall(r'localizedName":"(.*?)&quot', response.text)[0]

IndexError: list index out of range

Missing Spaces

A space should be added after the ',' preceding 'double-check' (L382):
[*] Hopefully that's the right company-name! If not,double-check LinkedIn and try again.

A space should be added between 'in' and 'the' (L720):
[*] All done! Check out your lovely new files inthe li2u-output directory.

Mobile API halts early

The mobile API in use stops scrolling around 800-1000 results. Tried upgrading to a premium account and confirmed the issue still exists. Also confirmed by manually recreating scrolling effect and watching results halt (that was boring).

Possible workarounds:

  • Stop using the scrolling API and use the page counter (will make the tool slower, limiting to 10 results per loop). Would have to update the li2u UI to not scroll for each result message. Might be fun.
  • Look at using the full featured site again (issues in the past with regexes here due to complexity of results loading via javascript)

Implement Selenium WebDriver for Auth

Maintaining the login function is a cat/mouse game. Having Selenium launch a browser, allowing the user to login there, and then closing it to get the cookies would reduce a lot of pain and troubleshooting.

This would solve most issues that get opened, and also support 2FA.

The existing login() function could be reduced to something like this:

def login():
    """Creates a new authenticated session.

    This now uses Selenium because I got very tired playing cat/mouse
    with LinkedIn's login process.
    """
    driver = webdriver.Firefox()
    driver.get("https://linkedin.com/login")

    # Pause until the user lets us know the session is good.
    input("Press Enter after you've logged in...")
    selenium_cookies = driver.get_cookies()
    driver.quit()

    # Initialize and return a requests session
    session = requests.Session()
    for cookie in selenium_cookies:
        session.cookies.set(cookie['name'], cookie['value'])

    return session

I'd also need to remove the username and password args.

I tried to test this just now, but ran into issues with Selenium and my Linux VM - probably either because it was Ubuntu using snaps as browsers, or because it was ARM64.

I can try to come back and test this later, but I am very open to help if someone else wants to give it a try.

Nice tool however, it doesn't give me results.

Hi!

I like the concept of this tool but it looks like it's failing to write all names to the files.
For example I tried this:
python3 linkedin2username.py -u [email] -p [Password] -c [REDACTED] -n [REDACTED] -d 51

The script succesfully finds 51 staffs but only writes 5 to a file.

[*] Using version 0.21, which is the latest on GitHub.                                                                                                                                                                                       
                                                                                                                                                                                                                                             
[*] Successfully logged in.                                                                                                                                                                                                                  
                                                                                                                                                                                                                                             
          ID:    3499405                                                                                                                                                                                                                     
          Alias: [REDACTED]
          Desc:  Your coach in digital security                                                                                                                                                                                              
          Staff: 51                                                                                                                                                                                                                          
          URL:   http://www.[REDACTED].com                                                                                                                                                                                                       
                                                                                                                                                                                                                                             
[*] Hopefully that's the right [REDACTED]! If not,double-check LinkedIn and try again.                                                                                                                                                           
                                                                                                                                                                                                                                             
[*] Starting search....

[*] Company has 51 profiles to check. Some may be anonymous.
[*] Setting each iteration to a maximum of 3 loops of 25 results each.



[*] Scraping results on loop 3...        [*] Added 0 new names. Running total: 6              

[*] All done! Check out your lovely new files inthe li2u-output directory.

result files are empty

Describe the bug
I can see user in linkedin but the tools return nothing
--> files are empty, no users

To Reproduce
/linkedin2username.py -u [email protected] -p password -c company

Verify Expected Results
all is ok in linkedin (there are anonymous and no-anonymous profiles)

Additional context
image

Recommendation for Name Parentheticals and Certificates

First off, really appreciate this tool and its regular updates!

I've had some general issues I've run into:

  1. Users who have names instead of certifications in parentheses. I've noticed more often than not, the certificates will simply be tacked on at the end.
  2. The extensive lists of certificates at the ends of names being taken as last names
    This results in names like:
    bob.cfa or dave.cba or john.pmp.

Parenthetical names

I have some really bad code dealing with the parenthetical names, but it butchers the existing code and moves some of the cleanup into the write function (which, if this is something you think is worth implementing, I would want to spend time to cleanup). So far it does this:

  1. If there are only 3 name parts and the middle is parenthetical, assume that middle is an alternative first name (I see this a lot with people who have non-english names). The result is two alternative email options with different first names. EG. Robert (Bob) Clark becomes robert.clark and bob.clark.
  2. If there are 2 name parts and the first has a parenthetical in it, it will break the name up and create two emails as well. EG. Robert(Bob) Clark becomes robert.clark and bob.clark.

Certifications

I have been collecting and using a list of certs I have run into in the past for a while, but I found it is pretty effective to use some regex to just find 2+ capitalized letters next to each other and deleting everything not a letter around it.
I use this in vim: %s/\W*[A-Z]\{2,}\W*//g

So not sure what direction you might want to take with this; I understand there's no perfect solution and people do all sorts of crazy things with their Linkedin names.

Off by 1 Running Total

Describe the bug
The running total is one more than the actual results (specifically the rawnames.txt):

[] Scraping results on loop 2... [] Added 7 new names. Running total: 7
[*] We have hit the end of the road! Moving on...

[] All done! Check out your lovely new files inthe li2u-output directory.
$ wc -l li2u-output/

8 li2u-output/we-are-example-f.last.txt
8 li2u-output/we-are-example-first.last.txt
6 li2u-output/we-are-example-first.txt
8 li2u-output/we-are-example-firstl.txt
8 li2u-output/we-are-example-flast.txt
8 li2u-output/we-are-example-lastf.txt
6 li2u-output/we-are-example-rawnames.txt
52 total

To Reproduce
$ python3 linkedin2username.py --geoblast -u <redacted> -c we-are-example -n example.com.au

Verify Expected Results
Have you verified that you can access the company page via the web UI, and that the expected amount of contacts are visible using your login?

Yes.

Additional context
Do you have any type of special setup? Web proxy, two-factor LI authentication, etc.

No. Tool version 0.21

KeyError: 'occupation'

The script has done few loops and got 292 results out of 392 employees, and than failed with this error

Python 3.10.12

[*] Hopefully that's the right XXX! If not, check LinkedIn and try again.

[*] Calculating inner and outer loops...
[*] Company has 392 profiles to check. Some may be anonymous.
[*] Setting each iteration to a maximum of 16 loops of 25 results each.

[*] Starting search.... Press Ctrl-C to break and write files early.

[*] Scraping results on loop 15...    Traceback (most recent call last):g total: 292              
  File "/home/server/Tools/linkedin2username/linkedin2username.py", line 694, in <module>
    main()
  File "/home/server/Tools/linkedin2username/linkedin2username.py", line 684, in main
    employees = do_loops(session, company_id, outer_loops, args)
  File "/home/server/Tools/linkedin2username/linkedin2username.py", line 573, in do_loops
    found_employees = find_employees(result.text)
  File "/home/server/Tools/linkedin2username/linkedin2username.py", line 508, in find_employees
    'occupation': profile['occupation']}
KeyError: 'occupation'

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.