LK_Scraper : An Fully Configurable LinkedIn Scrape

Lk_scraper is an fully configurable LinkedIn scrape : scrape anything within LinkedIn

Installation

$ pip install git+git://github.com/jqueguiner/lk_scraper

Setup

  • Using Docker compose

$ docker-compose up -d
$ docker-compose run lk_scraper python3

  • Using Docker only for selenium server

First, you need to run a selenium server

$ docker run -d -p 4444:4444 –shm-size 2g selenium/standalone-firefox:3.141.59-20200326

After running this command, from the browser navigate to your IP address followed by the port number and /grid/console. So the command will be http://localhost:4444/grid/console.

Also Read – Lollipopz : Data Exfiltration Utility For Testing Detection Capabilities

Retrieving Cookie

  • Browser-Independent:
  1. Navigate to Linkedin.com and log in
  2. Open up the browser developer tools (Ctrl-Shift-I or right click -> inspect element)
  • Chrome:
    • Select the Application tab
    • Under the Storage header on the left-hand menu, click the Cookies dropdown and select www.linkedin.com
    • Find the li_at cookie, and double click the value to select it before copying
  • Firefox:
    • Select Storage tab
    • Click the Cookies dropdown and select www.linkedin.com
    • Find and copy the li_at value

Setting Up The Cookie

  • Method 1 : Setting the cookie in the config file

You can add your LinkedIn li_at cookie in the config file that is located in your home (~/.lk_scraper/config.yml) see

  • Method 2 : Setting the cookie at the Scraper level

from lk_scraper import Scraper
li_at = “My_super_linkedin_cookie”
scraper = Scraper(li_at=li_at)

  • Method 3 : Using Variable Environment

(Not implemented Yet)

$ export LI_AT=”My_super_linkedin_cookie”

Example

run the jupyter notebook linkedin-example.ipynb

  • Usage

>>from lk_scraper import Scraper
>>scraper = Scraper()

  • Company Scraping

>>from lk_scraper import Scraper
>>scraper = Scraper()
>>company = scraper.get_object(object_name=’company’, object_id=’apple’)

  • Profile Scraping

>>from lk_scraper import Scraper
>>scraper = Scraper()
>>profil = scraper.get_object(object_name=’profil’, object_id=’jlqueguiner’)

R K

Recent Posts

Kali Linux 2024.4 Released, What’s New?

Kali Linux 2024.4, the final release of 2024, brings a wide range of updates and…

11 hours ago

Lifetime-Amsi-EtwPatch : Disabling PowerShell’s AMSI And ETW Protections

This Go program applies a lifetime patch to PowerShell to disable ETW (Event Tracing for…

11 hours ago

GPOHunter – Active Directory Group Policy Security Analyzer

GPOHunter is a comprehensive tool designed to analyze and identify security misconfigurations in Active Directory…

2 days ago

2024 MITRE ATT&CK Evaluation Results – Cynet Became a Leader With 100% Detection & Protection

Across small-to-medium enterprises (SMEs) and managed service providers (MSPs), the top priority for cybersecurity leaders…

5 days ago

SecHub : Streamlining Security Across Software Development Lifecycles

The free and open-source security platform SecHub, provides a central API to test software with…

1 week ago

Hawker : The Comprehensive OSINT Toolkit For Cybersecurity Professionals

Don't worry if there are any bugs in the tool, we will try to fix…

1 week ago