Git Product home page Git Product logo

py_mega_account_generator's Introduction

py_mega_account_generator

Generate MEGA accounts with a single command, upload files, get shareable links and do all of that however many times you want with loops.

Instructions

These instructions assume you have Git and Python 3.10 installed, if you do not have Git installed, then download the project from here and skip the first step below.

git clone https://github.com/qtchaos/py_mega_account_generator.git
cd py_mega_account_generator
pip install -r requirements.txt
python main.py

Usage

Note

The maximum upload size of a file is 20GB, since this is the limit on a free account.

You can use this program without any arguments at all, this will spit out a new account with the welcome pdf deleted, it will show the login credentials in the console and create a new file in the credentials folder. If you want to upload a file though, you can use the following setup: python main.py -f FILENAME -p, this will upload the file to a new account and print out a publicly shareable link. Unfortunately, it seems that MEGA likes to purge accounts that haven't been logged into for a while, so if it has been a while since you started generating new accounts, you might want to run the keepalive service: python main.py -ka -v, this will login to every account and print out the storage used. And if you want to mass create accounts or upload files, then you can use the loop argument: python main.py -p -f FILENAME -l TIMES_TO_LOOP.

Format

{"email": "*******@*******.com", "emailPassword": "*****", "password": "*********"}

The emailPassword represents the password used to create the mail.tm account.
If you want to login to the MEGA account later on, you have to use the email and password fields.

Custom format

If you want to change the format of the credentials file, you can do so by changing the accountFormat variable in the config.json file. Use the following variables to change the format:

  • {email} - The email used to create the MEGA account.
  • {emailPassword} - The password used to create the mail.tm account.
  • {password} - The password used to create the MEGA account.

For example, if you want to change the format to the following:

Then you would change the accountFormat variable to {email}#{password}, this will append credentials to a file called accounts.txt in the credentials folder. If you change the accountFormat variable to "", then it will use the default JSON file format and create a new file for every account.

Arguments

Warning

Do not use the arguments in the Services section together with the file upload arguments.

-f filename, --file filename | Uploads a file to the generated account.
-p, --public | Generates a shareable link to the file.
-l int, --loop int | Loops the script x amount of times.

Services

-ka, --keepalive | Logs into the accounts to keep them alive.
-v, --verbose | Shows storage left while using keepalive function.

py_mega_account_generator's People

Contributors

chikenscrach avatar dogancanyr avatar qtchaos 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

Watchers

 avatar  avatar

py_mega_account_generator's Issues

Future exception was never retrieved

HOPE! You are doing fine.

been facing some error !

Future exception was never retrieved
future: <Future finished exception=NetworkError('Protocol error (Target.sendMessageToTarget): No session with given id')>
pyppeteer.errors.NetworkError: Protocol error (Target.sendMessageToTarget): No session with given id
Future exception was never retrieved
future: <Future finished exception=NetworkError('Protocol error (Target.sendMessageToTarget): No session with given id')>
pyppeteer.errors.NetworkError: Protocol error (Target.sendMessageToTarget): No session with given id
Traceback (most recent call last):
File "D:\accountgenerator\py_mega_account_generator-master\main.py", line 155, in
asyncio.run(register(credentials, executable_path, config))
File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\asyncio\runners.py", line 44, in run
return loop.run_until_complete(main)
File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\asyncio\base_events.py", line 649, in run_until_complete
return future.result()
File "D:\accountgenerator\py_mega_account_generator-master\main.py", line 114, in register
await initial_setup(context, message, credentials)
File "D:\accountgenerator\py_mega_account_generator-master\utilities\web.py", line 44, in initial_setup
await confirm_page.waitForSelector("#freeStart", timeout=10000)
File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\pyppeteer\frame_manager.py", line 855, in await
raise result
pyppeteer.errors.TimeoutError: Waiting for selector "#freeStart" failed: timeout 10000ms exceeds.

Screenshot 2024-01-23 195319

and is there a way to create multiple account without giving any filename !!

ModuleNotFoundError: No module named 'tenacity._asyncio'

Hi, I recently filed a bug report from my desktop, and the latest update fixed the bug, however when I try to use this script on my laptop, I keep getting an error. I have run all the required commands, including installing the required modules, and have also tried repairing python, none of which worked. Here is a full log of my terminal:

Microsoft Windows [Version 10.0.19045.3570]
(c) Microsoft Corporation. All rights reserved.

C:\Users\viper\py_mega_account_generator>python main.py
Traceback (most recent call last):
  File "C:\Users\viper\py_mega_account_generator\main.py", line 8, in <module>
    from utilities.etc import p_print, clear_console, Colours, clear_tmp, reinstall_tenacity, check_for_updates, delete_default
  File "C:\Users\viper\py_mega_account_generator\utilities\etc.py", line 7, in <module>
    from mega import Mega
  File "C:\Users\viper\AppData\Local\Programs\Python\Python312\Lib\site-packages\mega\__init__.py", line 1, in <module>
    from .mega import Mega  # noqa
    ^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\viper\AppData\Local\Programs\Python\Python312\Lib\site-packages\mega\mega.py", line 18, in <module>
    from tenacity import retry, wait_exponential, retry_if_exception_type
  File "C:\Users\viper\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\__init__.py", line 451, in <module>
    from tenacity._asyncio import AsyncRetrying
ModuleNotFoundError: No module named 'tenacity._asyncio'

C:\Users\viper\py_mega_account_generator>

It seems this is only an issue on my laptop, so it may be an issue on my end.

need help with file storage and keep alive features

hello. Thank you for this awesome generator. Though I can't login into accounts(screenshot shared).

Also I need to know I have many Generated mega accounts which just have their Login Email And Password, so is there any ways I can put them into .json files and login through your tool. Appreciate your work.

Hoping for a reply soon.
Thank you.
111111

Error

image
what is the error here?

pyppeteer.errors.TimeoutError: Waiting for selector "#freeStart" failed: timeout 10000ms exceeds.

Please enter the path to a Chromium based browser's executable: C:\Program Files\Google\Chrome\Application\chrome.exe
Found executable!
Registered account successfully!
Retrieved mail successfully!
Found mail!
Traceback (most recent call last):
  File "C:\Users\Lakshit\Desktop\py_mega_account_generator\main.py", line 155, in <module>
    asyncio.run(register(credentials, executable_path, config))
  File "C:\Users\Lakshit\AppData\Local\Programs\Python\Python310\lib\asyncio\runners.py", line 44, in run
    return loop.run_until_complete(main)
  File "C:\Users\Lakshit\AppData\Local\Programs\Python\Python310\lib\asyncio\base_events.py", line 649, in run_until_complete
    return future.result()
  File "C:\Users\Lakshit\Desktop\py_mega_account_generator\main.py", line 114, in register
    await initial_setup(context, message, credentials)
  File "C:\Users\Lakshit\Desktop\py_mega_account_generator\utilities\web.py", line 44, in initial_setup
    await confirm_page.waitForSelector("#freeStart", timeout=10000)
  File "C:\Users\Lakshit\AppData\Local\Programs\Python\Python310\lib\site-packages\pyppeteer\frame_manager.py", line 855, in __await__
    raise result
pyppeteer.errors.TimeoutError: Waiting for selector "#freeStart" failed: timeout 10000ms exceeds.

keep mega accounts alive

Hi its me again :)
can you maybe add a option to log into your accounts so that they dont get deleted by mega? Because mega deletes accounts that are 3 months inactive. So can you maybe add a option that it can read the mail and pass from the credential folder so it can log into all of them if its possible and if you have time to do this?😁

Option to delete the "Welcome to Mega.pdf" file

First of all, thanks for your script and the latest updates.

I would like to have an option, or maybe a default behavior (since the file is useless), to delete the "Welcome" file that Mega creates when a new account is registered. Other scripts, like the one from f-o, has this option by default.

Already been asked & resolved before and I'm using the latest version which shall counter this problem already but here is it - [pyppeteer.errors.TimeoutError]

Hello mate,

Got this error.

Failed to clear temporary files... killing previous instances. Killing process msedgewebview2.exe... Killing process msedge.exe... Killed previous instances successfully! Failed to clear temporary files... killing previous instances. Killing process msedgewebview2.exe... Killed previous instances successfully! Registered account successfully! Retrieved mail successfully! Found mail! Traceback (most recent call last): File "P:\py_mega_account_generator-master(2)\py_mega_account_generator-master\main.py", line 138, in <module> asyncio.run(register(asyncio.run(generate_mail()))) File "C:\Python310\lib\asyncio\runners.py", line 44, in run return loop.run_until_complete(main) File "C:\Python310\lib\asyncio\base_events.py", line 649, in run_until_complete return future.result() File "P:\py_mega_account_generator-master(2)\py_mega_account_generator-master\main.py", line 76, in register await initial_setup(context, message, credentials) File "P:\py_mega_account_generator-master(2)\py_mega_account_generator-master\utilities\web.py", line 43, in initial_setup await confirm_page.waitForSelector("#freeStart", timeout=1000) File "C:\Python310\lib\site-packages\pyppeteer\frame_manager.py", line 855, in __await__ raise result pyppeteer.errors.TimeoutError: Waiting for selector "#freeStart" failed: timeout 1000ms exceeds.

I haven't created even 1 account so far - to answer the question you asked the other user with this same issue.

Thanks for reading.

pyppeteer error TimeoutError

Traceback (most recent call last):
  File "D:\Scripts\Mega\main.py", line 93, in <module>
    asyncio.run(register(asyncio.run(generate_mail())))
  File "C:\Users\N0N3\AppData\Local\Programs\Python\Python39\lib\asyncio\runners.py", line 44, in run
    return loop.run_until_complete(main)
  File "C:\Users\N0N3\AppData\Local\Programs\Python\Python39\lib\asyncio\base_events.py", line 642, in run_until_complete
    return future.result()
  File "D:\Scripts\Mega\main.py", line 59, in register
    await type_name(page, credentials)
  File "D:\Scripts\Mega\utilities\web.py", line 88, in type_name
    await page.waitForSelector("#register_form")
  File "C:\Users\N0N3\AppData\Local\Programs\Python\Python39\lib\site-packages\pyppeteer\frame_manager.py", line 855, in __await__
    raise result
pyppeteer.errors.TimeoutError: Waiting for selector "#register_form" failed: timeout 30000ms exceeds.

this is insane

Hi bro
I have no issue I just wanted to say that this is awesome. Keep it up
Btw can I create unlimited Accounts with this script?

[Request] a way to not only use chrome

Hi
The new update works great👍🏻 I just wanted to ask if it's possible to use more than just chrome. I had to download it specifically for this. I have brave and edge. Maybe it's possible that I can choose one of them instead of installing Chrome specifically for it.

Thanks for the updates and the good work

Mega´s region specific start file

Mega creates the start file wich sould get deleted by the programm, how ever, this file changes it´s name depending on the country.
E.g. "Willkommen zu MEGA.pdf" in german.
It was a quick fix though and i just wanted to say that. :)

Browser closed unexpectedly

I'm encountering an error when running:

Retrying mail.tm account generation...
Traceback (most recent call last):
  File "C:\Users\viper\py_mega_account_generator\main.py", line 138, in <module>
    asyncio.run(register(asyncio.run(generate_mail())))
  File "C:\Users\viper\AppData\Local\Programs\Python\Python39-32\lib\asyncio\runners.py", line 44, in run
    return loop.run_until_complete(main)
  File "C:\Users\viper\AppData\Local\Programs\Python\Python39-32\lib\asyncio\base_events.py", line 642, in run_until_complete
    return future.result()
  File "C:\Users\viper\py_mega_account_generator\main.py", line 56, in register
    browser = await pyppeteer.launch({
  File "C:\Users\viper\AppData\Local\Programs\Python\Python39-32\lib\site-packages\pyppeteer\launcher.py", line 307, in launch
    return await Launcher(options, **kwargs).launch()
  File "C:\Users\viper\AppData\Local\Programs\Python\Python39-32\lib\site-packages\pyppeteer\launcher.py", line 168, in launch
    self.browserWSEndpoint = get_ws_endpoint(self.url)
  File "C:\Users\viper\AppData\Local\Programs\Python\Python39-32\lib\site-packages\pyppeteer\launcher.py", line 227, in get_ws_endpoint
    raise BrowserError('Browser closed unexpectedly:\n')
pyppeteer.errors.BrowserError: Browser closed unexpectedly:


C:\Users\viper\py_mega_account_generator>

What could be the causation?

Hmmmm.

PS C:\Users\Dogan\Desktop\py_mega_account_generator-master> python main.py
Traceback (most recent call last):
  File "C:\Users\Dogan\Desktop\py_mega_account_generator-master\main.py", line 8, in <module>
    from utilities.etc import p_print, clear_console, Colours, clear_tmp, reinstall_tenacity, check_for_updates, delete_default
  File "C:\Users\Dogan\Desktop\py_mega_account_generator-master\utilities\etc.py", line 7, in <module>
    from mega import Mega
  File "C:\Users\Dogan\AppData\Local\Programs\Python\Python312\Lib\site-packages\mega\__init__.py", line 1, in <module>
    from .mega import Mega  # noqa
    ^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\Dogan\AppData\Local\Programs\Python\Python312\Lib\site-packages\mega\mega.py", line 18, in <module>
    from tenacity import retry, wait_exponential, retry_if_exception_type
  File "C:\Users\Dogan\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\__init__.py", line 451, in <module>
    from tenacity._asyncio import AsyncRetrying
  File "C:\Users\Dogan\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\_asyncio.py", line 33, in <module>
    class AsyncRetrying(BaseRetrying):
  File "C:\Users\Dogan\AppData\Local\Programs\Python\Python312\Lib\site-packages\tenacity\_asyncio.py", line 41, in AsyncRetrying
    @asyncio.coroutine
     ^^^^^^^^^^^^^^^^^
AttributeError: module 'asyncio' has no attribute 'coroutine'. Did you mean: 'coroutines'?

#freeStart timeout error.

Killed previous instances successfully!
Registered account successfully!
Retrieved mail successfully!
Found mail!
Traceback (most recent call last):
  File "C:\Users\Dogan\Desktop\py_mega_account_generator-master\main.py", line 138, in <module>
    asyncio.run(register(asyncio.run(generate_mail())))
  File "C:\Users\Dogan\AppData\Local\Programs\Python\Python310\lib\asyncio\runners.py", line 44, in run
    return loop.run_until_complete(main)
  File "C:\Users\Dogan\AppData\Local\Programs\Python\Python310\lib\asyncio\base_events.py", line 641, in run_until_complete
    return future.result()
  File "C:\Users\Dogan\Desktop\py_mega_account_generator-master\main.py", line 76, in register
    await initial_setup(context, message, credentials)
  File "C:\Users\Dogan\Desktop\py_mega_account_generator-master\utilities\web.py", line 43, in initial_setup
    await confirm_page.waitForSelector("#freeStart", timeout=1000)
  File "C:\Users\Dogan\AppData\Local\Programs\Python\Python310\lib\site-packages\pyppeteer\frame_manager.py", line 855, in __await__
    raise result
pyppeteer.errors.TimeoutError: Waiting for selector "#freeStart" failed: timeout 1000ms exceeds.

Requesting new features

It would be nice if you added an option to loop the account creation so you would be able to make a lot of accounts without having to type every time "python main.py". Also a proxy feature would be nice so the accounts would come from a different ip address.

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.