Skip to content

Commit

Permalink
Merge pull request #150 from Datalux/development
Browse files Browse the repository at this point in the history
Development version (1.3)
  • Loading branch information
Datalux authored May 17, 2021
2 parents 12af340 + d233803 commit a3d5ad1
Show file tree
Hide file tree
Showing 8 changed files with 247 additions and 81 deletions.
13 changes: 7 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Osintgram 🔎📸

[![version-1.2](https://img.shields.io/badge/version-1.2-green)](https://github.com/Datalux/Osintgram/releases/tag/1.2)
[![version-1.3](https://img.shields.io/badge/version-1.3-green)](https://github.com/Datalux/Osintgram/releases/tag/1.3)
[![GPLv3](https://img.shields.io/badge/license-GPLv3-blue)](https://img.shields.io/badge/license-GPLv3-blue)
[![Python3](https://img.shields.io/badge/language-Python3-red)](https://img.shields.io/badge/language-Python3-red)
[![Telegram](https://img.shields.io/badge/Telegram-Channel-blue.svg)](https://t.me/osintgram)
Expand All @@ -9,10 +9,10 @@
Osintgram is a **OSINT** tool on Instagram to collect, analyze, and run reconnaissance.

<p align="center">
<img align="center" src=".img/carbon.svg" width="900">
<img align="center" src=".img/carbon.png" width="900">
</p>

Disclaimer: **The contributors do not assume any responsibility for the use of this tool**
Disclaimer: **FOR EDUCATIONAL PURPOSE ONLY! The contributors do not assume any responsibility for the use of this tool.**

Warning: It is advisable to **not** use your own/primary account when using this tool.

Expand Down Expand Up @@ -45,7 +45,7 @@ Osintgram offers an interactive shell to perform analysis on Instagram account o

You can find detailed commands usage [here](doc/COMMANDS.md).

[**Latest version**](https://github.com/Datalux/Osintgram/releases/tag/1.2) |
[**Latest version**](https://github.com/Datalux/Osintgram/releases/tag/1.3) |
[Commands](doc/COMMANDS.md) |
[CHANGELOG](doc/CHANGELOG.md)

Expand Down Expand Up @@ -73,9 +73,10 @@ You can find detailed commands usage [here](doc/COMMANDS.md).

Alternatively, you can run the `make setup` command to populate this file for you.

7. Run the main.py script
7. Run the main.py script in one of two ways

`python3 main.py <target username>`
* As an interactive prompt `python3 main.py <target username>`
* Or execute your command straight away `python3 main.py <target username> --command <command>`

## Docker Quick Start 🐳

Expand Down
4 changes: 2 additions & 2 deletions config/credentials.ini
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[Credentials]
username =
password =
username =
password =
2 changes: 1 addition & 1 deletion config/settings.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{}
{"uuid": "49ed550a-b30f-11eb-ab45-00155d9a47a8", "device_id": "android-49ed5762b30f11eb", "ad_id": "00ea607f-90b5-01af-95ac-c6f37ac93fbd", "session_id": "49ed5848-b30f-11eb-ab45-00155d9a47a8", "cookie": {"__class__": "bytes", "__value__": "gASVRwMAAAAAAAB9lIwOLmluc3RhZ3JhbS5jb22UfZSMAS+UfZQojAljc3JmdG9rZW6UjA5odHRw\nLmNvb2tpZWphcpSMBkNvb2tpZZSTlCmBlH2UKIwHdmVyc2lvbpRLAIwEbmFtZZSMCWNzcmZ0b2tl\nbpSMBXZhbHVllIwgemxlTm5zWjBJeUFPa0NPTzkwVG5rOUc0RHJDbFIzcHCUjARwb3J0lE6MDnBv\ncnRfc3BlY2lmaWVklImMBmRvbWFpbpSMDi5pbnN0YWdyYW0uY29tlIwQZG9tYWluX3NwZWNpZmll\nZJSIjBJkb21haW5faW5pdGlhbF9kb3SUiIwEcGF0aJRoA4wOcGF0aF9zcGVjaWZpZWSUiIwGc2Vj\ndXJllIiMB2V4cGlyZXOUSgCUe2KMB2Rpc2NhcmSUiYwHY29tbWVudJROjAtjb21tZW50X3VybJRO\njAdyZmMyMTA5lImMBV9yZXN0lH2UdWKMA21pZJRoCCmBlH2UKGgLSwBoDGggaA6MHFlKdXhfUUFC\nQUFHUmtGeFRzblNuek5DakpCdXCUaBBOaBGJaBKMDi5pbnN0YWdyYW0uY29tlGgUiGgViGgWaANo\nF4hoGIhoGUr9GF5kaBqJaBtOaBxOaB2JaB59lHVijANydXKUaAgpgZR9lChoC0sAaAxoJmgOjANO\nQU+UaBBOaBGJaBKMDi5pbnN0YWdyYW0uY29tlGgUiGgViGgWaANoF4hoGIhoGU5oGohoG05oHE5o\nHYloHn2UjAhIdHRwT25seZROc3VijApkc191c2VyX2lklGgIKYGUfZQoaAtLAGgMaC1oDowLNDc2\nNTU2NjY1MjeUaBBOaBGJaBKMDi5pbnN0YWdyYW0uY29tlGgUiGgViGgWaANoF4hoGIhoGUoAWRJh\naBqJaBtOaBxOaB2JaB59lHVijAlzZXNzaW9uaWSUaAgpgZR9lChoC0sAaAxoM2gOjCA0NzY1NTY2\nNjUyNyUzQUFkSjZxZkhDZGt2SHdpJTNBM5RoEE5oEYloEowOLmluc3RhZ3JhbS5jb22UaBSIaBWI\naBZoA2gXiGgYiGgZSoDlfGJoGoloG05oHE5oHYloHn2UjAhIdHRwT25seZROc3VidXNzLg==\n"}, "created_ts": 1620816384}
13 changes: 13 additions & 0 deletions doc/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
# Changelog

## [1.3](https://github.com/Datalux/Osintgram/releases/tag/1.3)
**Enhancements**
- Artwork refactoring (#149)
- Added command line mode (#155)
- Added output limiter (#201)

**Bug fixes**
- Losing collected data (#156)
- JSON user info (#202)
- Issue #198 (#200)
- Issue #204 (12e730e)


## [1.2](https://github.com/Datalux/Osintgram/releases/tag/1.2)
**Enhancements**
- Added virtual environment (#126)
Expand Down
48 changes: 32 additions & 16 deletions main.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
from src.Osintgram import Osintgram
import argparse
from src import printcolors as pc
from src import artwork
import sys
import signal

Expand All @@ -16,14 +17,8 @@


def printlogo():
pc.printout("________ .__ __ \n", pc.YELLOW)
pc.printout("\_____ \ _____|__| _____/ |_ ________________ _____ \n", pc.YELLOW)
pc.printout(" / | \ / ___/ |/ \ __\/ ___\_ __ \__ \ / \ \n", pc.YELLOW)
pc.printout("/ | \\\___ \| | | \ | / /_/ > | \// __ \| Y Y \\\n", pc.YELLOW)
pc.printout("\_______ /____ >__|___| /__| \___ /|__| (____ /__|_| /\n", pc.YELLOW)
pc.printout(" \/ \/ \/ /_____/ \/ \/ \n", pc.YELLOW)
print('\n')
pc.printout("Version 1.2 - Developed by Giuseppe Criscione\n\n", pc.YELLOW)
pc.printout(artwork.ascii_art, pc.YELLOW)
pc.printout("\nVersion 1.1 - Developed by Giuseppe Criscione\n\n", pc.YELLOW)
pc.printout("Type 'list' to show all allowed commands\n")
pc.printout("Type 'FILE=y' to save results to files like '<target username>_<command>.txt (default is disabled)'\n")
pc.printout("Type 'FILE=n' to disable saving to files'\n")
Expand All @@ -39,6 +34,8 @@ def cmdlist():
print("Enable/disable export in a '<target username>_<command>.json' file'")
pc.printout("addrs\t\t")
print("Get all registered addressed by target photos")
pc.printout("cache\t\t")
print("Clear cache of the tool")
pc.printout("captions\t")
print("Get target's photos captions")
pc.printout("commentdata\t")
Expand Down Expand Up @@ -108,18 +105,21 @@ def _quit():
gnureadline.parse_and_bind("tab: complete")
gnureadline.set_completer(completer)

printlogo()

parser = argparse.ArgumentParser(description='Osintgram is a OSINT tool on Instagram. It offers an interactive shell '
'to perform analysis on Instagram account of any users by its nickname ')
parser.add_argument('id', type=str, # var = id
help='username')
parser.add_argument('-C','--cookies', help='clear\'s previous cookies', action="store_true")
parser.add_argument('-j', '--json', help='save commands output as JSON file', action='store_true')
parser.add_argument('-f', '--file', help='save output in a file', action='store_true')
parser.add_argument('-c', '--command', help='run in single command mode & execute provided command', action='store')
parser.add_argument('-o', '--output', help='where to store photos', action='store')

args = parser.parse_args()

api = Osintgram(args.id, args.file, args.json)

api = Osintgram(args.id, args.file, args.json, args.command, args.output, args.cookies)



commands = {
Expand All @@ -128,6 +128,7 @@ def _quit():
'quit': _quit,
'exit': _quit,
'addrs': api.get_addrs,
'cache': api.clear_cache,
'captions': api.get_captions,
"commentdata": api.get_comment_data,
'comments': api.get_total_comments,
Expand All @@ -151,6 +152,7 @@ def _quit():
'wtagged': api.get_people_who_tagged
}


signal.signal(signal.SIGINT, signal_handler)
if is_windows:
pyreadline.Readline().parse_and_bind("tab: complete")
Expand All @@ -159,14 +161,25 @@ def _quit():
gnureadline.parse_and_bind("tab: complete")
gnureadline.set_completer(completer)

if not args.command:
printlogo()


while True:
pc.printout("Run a command: ", pc.YELLOW)
cmd = input()
if args.command:
cmd = args.command
_cmd = commands.get(args.command)
else:
signal.signal(signal.SIGINT, signal_handler)
gnureadline.parse_and_bind("tab: complete")
gnureadline.set_completer(completer)
pc.printout("Run a command: ", pc.YELLOW)
cmd = input()

_cmd = commands.get(cmd)

_cmd = commands.get(cmd)

if _cmd:
_cmd()
_cmd()
elif cmd == "FILE=y":
api.set_write_file(True)
elif cmd == "FILE=n":
Expand All @@ -179,3 +192,6 @@ def _quit():
print("")
else:
pc.printout("Unknown command\n", pc.RED)

if args.command:
break
2 changes: 1 addition & 1 deletion output/dont_delete_this_folder.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Please don't deleate this folder.
Please don't delete this folder.
Loading

0 comments on commit a3d5ad1

Please sign in to comment.