Skip to content

Commit

Permalink
Cleanup for new plans (#52)
Browse files Browse the repository at this point in the history
  • Loading branch information
bmmpxf committed Jan 31, 2020
1 parent 46a38e9 commit 18e9b75
Show file tree
Hide file tree
Showing 9 changed files with 93 additions and 98 deletions.
2 changes: 1 addition & 1 deletion docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
# -- Project information -----------------------------------------------------

project = 'MythX'
copyright = '2019, MythX'
copyright = '2020, MythX'
author = 'MythX'

# The short X.Y version
Expand Down
42 changes: 26 additions & 16 deletions docs/source/getting-started/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,22 +17,25 @@ To use MythX, you need to create an account.

#. Fill out the registration form. You will need to supply a valid email address.

.. image:: img/registration2.png
.. figure:: img/registration2.png
:width: 50%

#. When finished, click :guilabel:`Complete Registration`.

#. A success message will show, indicating your account has been created successfully. You will be sent an email to verify your email address.

.. image:: img/success.png
.. figure:: img/success.png
:width: 50%

.. note:: It is recommended that you link your Ethereum account to your profile as you will use this credential along with your password to access the MythX API via client tools such as Remix.
.. note::

.. image:: img/metamask1.png
:width: 50%
It is recommended that you link your Ethereum account to your profile as you will use this credential along with your password to access the MythX API via client tools such as Remix. This is done with `MetaMask <https://metamask.io>`_.

.. figure:: img/metamask1.png

Once linked, MetaMask will ask to sign a transaction to connect to MythX.

.. image:: img/metamasksignup.png
.. figure:: img/metamasksignup.png
:width: 50%

.. Verify this
Expand All @@ -43,7 +46,7 @@ Linking your account with tools

Your account, once verified, is on the Free plan.

.. note:: MythX offers both free and paid plans. For information on plans and features, please see our `Plans <https://mythx.io/plans/>`_ page.
.. note:: MythX offers both free and paid plans. For information on plans and features, please see our `Pricing <https://mythx.io/plans/>`_ page.

If using one of the :ref:`tools`, you will need to link your account to the tool to take advantage of your account's plan.

Expand All @@ -55,24 +58,31 @@ While the specifics of each tool differ, most tools will pick up your account in
* - Environment variable
- Value
* - ``MYTHX_API_KEY``
- API Key
- <Your API key>

MythX uses an API key for authentication. This API key can be generated in your `dashboard <https://dashboard.mythx.io/>`_. In the Profile tab there is a section titled :guilabel:`MythX API Key`. Generate a new API key by entering your account password:

.. figure:: img/api-key-password.png

Authentication
~~~~~~~~~~~~~~
On successful authentication, a new API key is generated, which can be used for further authentication by API clients. It will only be shown once, and can be copied using the icon on the right of the truncated secret string. If the token is lost, a new one can be generated again in the same way as explained above.

MythX uses an API key for authentication. Once your account is set up, head over to the `dashboard <https://dashboard.mythx.io/>`_. In the *Profile* section there is an element labeled :guilabel:`MythX API Key`. Generate a new API key by entering your account password:
.. figure:: img/api-key.png

.. image:: img/api-key-password.png
This key can be passed to MythX as an environment variable :code:`MYTHX_API_KEY`.

On successful authentication, a new API key is generated, which can be used for further authentication by API clients. It will only be shown once, and can be copied using the icon on the right of the truncated secret string. If the token is lost, a new one can be generated again in the same way as explained above.
* **Linux / macOS**:

.. code-block:: console
export MYTHX_API_KEY='put your API key here!'
.. image:: img/api-key.png
* **Windows**:

This key can be passed to the MythX Security tool as an environment variable :code:`MYTHX_API_KEY`.
.. code-block:: console
.. note:: Although using the API key is the recommended means of authentication, there are certain tools that do net yet support the API token (for example, Remix). For these tools, you can authenticate via Ethereum address/Username and Password.
set MYTHX_API_KEY='put your API key here!'
.. note:: Although using the API key is the recommended means of authentication, there are certain tools that do not yet support the API token (for example: :ref:`Remix <tools.remix>`). For these tools, you can authenticate via your Ethereum address or user name and password.

Please see :ref:`the specific page for your tool <tools>` to see more details about linking your account.

27 changes: 7 additions & 20 deletions docs/source/getting-support/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,30 +6,17 @@
MythX support
=============

There are multiple ways to get in touch with us, whether you want to get help using MythX, you want to develop an integration, or you want to give feedback.
There are multiple ways to get in touch with us, whether you want to get help using MythX, develop an integration, or give feedback.


Users
-----
* You can connect with the MythX team by joining the `MythX Community <https://community.mythx.io>`_.

You can connect with the MythX team on Discord at `#mythx-support <https://discord.gg/E3YrVtG>`_.
* To get support for third-party tools it is usually best to communicate directly with the tool developers. For example:

To get support for third-party tools it is usually best to communicate directly with the tool developers. For example:
* If you run into an issue with the :ref:`MythX plugin for Truffle <tools.truffle>`, create an issue in its `GitHub repository <https://github.com/ConsenSys/truffle-security>`_.
* For issues with the :ref:`MythX Remix plugin <tools.remix>`, you can create an issue in the `Remix plugin GitHub repository <https://github.com/aquiladev/remix-mythx-plugin/>`_ as well.

* If you run into an issue with the :ref:`MythX plugin for Truffle <tools.truffle>`, create an issue in its `GitHub repository <https://github.com/ConsenSys/truffle-security>`_.
* For issues with the :ref:`MythX Remix plugin <tools.remix>`, you can create an issue in the `Remix plugin GitHub repository <https://github.com/aquiladev/remix-mythx-plugin/>`_ as well.
* For direct support, please go to `mythx.io <https://mythx.io>`_ and click the :guilabel:`Contact` link.

For direct support, please go to `mythx.io <https://mythx.io>`_ and click the :guilabel:`Contact` link.

Tool developers
---------------

If you're building tools on our MythX API you can reach out to our team on the following channels:

* `Discord: #mythx-tool-developers <https://discord.gg/dZTvEzA>`_ - General chat for MythX builders
* `Discord: #api-bugs <https://discord.gg/uXyHdyU>`_ - For reporting bugs in the MythX service

.. * `Github repository for developer support and API bug reports <https://github.com/ConsenSys/mythx-developer-support>`_ - create an issue here if you encounter crashes, errors, false positives or false negatives.
For direct support, please go to `mythx.io <https://mythx.io>`_ and click the :guilabel:`Contact` link.
We always want to hear from you, so thank you for getting in touch.

16 changes: 4 additions & 12 deletions docs/source/tools/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,26 +15,18 @@ Current tools
:maxdepth: 1

Truffle <truffle/index>
MythX CLI <mythx-cli/index>
Remix <remix/index>
VS Code <mythxvsc/index>
MythX CLI <mythx-cli/index>
GuardRails <guardrails/index>
Mythos <mythos/index>
Brownie <brownie/index>
VS Code <mythxvsc/index>

.. Make sure to change the Meta description when new tools are added!
New tools wanted
----------------

Are you working on an integration with an IDE, a web interface, or something
else that's super useful? If you are building on MythX, we want to know about
it!

Please join our community on `Discord <https://discord.gg/kktn8Wt>`_ and
reach out to the team for more information.

.. note::
Are you working on an integration with an IDE, a web interface, or something else that's super useful? If you are building on MythX, we want to know about it!

We plan to offer a revenue sharing system for qualifying tools. More
details will be announced soon.
Please join our `MythX Community <https://community.mythx.io>`_ and reach out to the team for more information.
10 changes: 6 additions & 4 deletions docs/source/tools/mythx-cli/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
MythX CLI Guide: Installation & Usage
=====================================

.. note:: See the `MythX CLI documentation <https://mythx-cli.readthedocs.io>`_ for full details on usage.

The `MythX CLI <https://github.com/dmuhs/mythx-cli/>`_ Python package aims to
provide a simple to use command line interface for the MythX API. It's main
purpose is to demonstrate how advanced features can be implemented using the
Expand Down Expand Up @@ -47,14 +49,14 @@ Installation

The MythX CLI runs on Python 3.6+, including 3.8-dev and pypy.

To get started, simply run
To get started, run:

.. code-block:: console
$ pip install mythx-cli
Advanced Usage
Advanced usage
--------------

For in-depth details on how to use the MythX CLI, alternative ways to install
Expand All @@ -68,12 +70,12 @@ For more information on how to get involved, check out our
`Contribution guidelines <https://mythx-cli.readthedocs.io/en/latest/contributing.html>`_.


Useful Links
Useful links
------------

.. list-table::

* - Github repository
* - GitHub repository
- https://github.com/dmuhs/mythx-cli/
* - Documentation
- https://mythx-cli.readthedocs.io/
Expand Down
24 changes: 12 additions & 12 deletions docs/source/tools/mythxvsc/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -40,42 +40,42 @@ Install_ from the Visual Studio marketplace.
Authentication
--------------

MythX uses an API key for authentication. Once your account is set up, head over to the `dashboard <https://dashboard.mythx.io/>`_. In the *Profile* section there is an element labeled :guilabel:`MythX API Key`. Generate a new API key by entering your account password:
MythX uses an API key for authentication. This API key can be generated in your `dashboard <https://dashboard.mythx.io/>`_. In the Profile tab there is a section titled :guilabel:`MythX API Key`. Generate a new API key by entering your account password:

.. image:: img/api-key-password.png
.. figure:: img/api-key-password.png

On successful authentication, a new API key is generated, which can be used for further authentication by API clients. It will only be shown once, and can be copied using the icon on the right of the truncated secret string. If the token is lost, a new one can be generated again in the same way as explained above.

.. image:: img/api-key.png
.. figure:: img/api-key.png

After installing the extension, copy the token and paste it in the VS Code user settings as shown below.

.. image:: img/vscapikey.png
.. figure:: img/vscapikey.png

.. warning::

Authentication via Ethereum address/Username and password is deprecated. Please note that the credentials stored this way are exposed to VS Code. Be sure to understand the security risk this entails or contact the extension developers if you don’t.
Authentication via Ethereum address or user name and password is deprecated.


Usage
-----

Open a Solidity file from inside a folder or workspace, and click the :guilabel:`MythX: Analyze smart contract` button that you will see in the top right of your IDE window. Otherwise, right click with your mouse on the contract name and you will see the command there.

.. image:: img/button_one.png
.. image:: img/right_click.png
.. figure:: img/button_one.png
.. figure:: img/right_click.png


MythX allows users to choose from three different scan modes. This extension supports all three.

.. image:: img/vscscanmodes.png
.. figure:: img/vscscanmodes.png

.. note:: Refer to the `plans <https://mythx.io/plans/>`_ page to see which plan you need for each mode.
.. note:: Different plans have access to different modes. Please refer to the MythX `Pricing <https://mythx.io/plans/>`_ page to see which plan you need for each mode.

Once the solidity compilation is done, you will be asked to pick a contract from a dropdown list of contracts that exist in the compiled AST. Please make sure to pick the main contract to avoid inconsistent results.

.. image:: img/contract_picker.png
.. figure:: img/contract_picker.png

Once the analysis is over, you will see your smart contract issues highlighted in your code. The exact time it takes to perform an analysis will depend on the mode selected & the plan associated with your account.
Once the analysis is over, you will see your smart contract issues highlighted in your code. The exact time it takes to perform an analysis will depend on the mode selected and the plan associated with your account.

.. image:: img/finished_analysis.png
.. figure:: img/finished_analysis.png
Binary file modified docs/source/tools/remix/img/mythxcreds2.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 5 additions & 5 deletions docs/source/tools/remix/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ MythX is available as a plugin for `Remix <https://remix.ethereum.org>`_, a popu
Setup
-----

.. note:: These instructions will show the Remix interface that is current as of early-2020. We recommend everyone use this interface.
.. note:: These instructions will show the Remix interface that is current as of early 2020. We recommend everyone use this interface.

Because Remix is a web-based interface, no local installation is required. However, MythX will need to be specifically activated from within the Remix Plugin Manager before use.

Expand All @@ -37,11 +37,11 @@ To activate MythX in Remix:
Authentication
--------------

#. Click the MythX logo and enter your MythX credentials. This consists of your Ethereum address (You can also enter your email) and your account password `mythx.io <https://mythx.io>`_. When done, click :guilabel:`Save`.
#. Click the MythX logo and enter your MythX credentials. This consists of your Ethereum address and your account password. (You can also enter your registered email address instead of your Ethereum address.) When done, click :guilabel:`Save`.

.. figure:: img/mythxcreds2.png

.. note:: You need to link your Ethereuem account to your MythX account (can be setup via https://mythx.io) to use MythX with Remix.
.. note:: You need to link your Ethereum account to your MythX account to use MythX with Remix. See the :ref:`getting-started` page for more details.

Usage
-----
Expand All @@ -52,11 +52,11 @@ To perform an analysis:

#. Click the MythX logo on the sidebar to open the MythX control panel (if it isn't already open).

#. Below the credentials section, there will be a select box containing a list of all applicable contracts. Select the contract you wish to analyze and click the :guilabel:`Analyze` button. You can also select the scan mode as shown below:
#. Below the credentials section, there will be a box containing a list of all applicable contracts. Select the contract you wish to analyze and click the :guilabel:`Analyze` button. You can also select the scan mode as shown below:

.. figure:: img/remixscanmodes.png

Refer to the `plans <https://mythx.io/plans/>`_ page to see which plan you need for each mode.
.. note:: Different plans have access to different modes. Please refer to the MythX `Pricing <https://mythx.io/plans/>`_ page to see which plan you need for each mode.

.. note:: The contract may need to be compiled first, depending on the current Remix settings. Make sure the :guilabel:`Solidity Compiler` plugin for Remix is activated in your project. You will have to click the Solidity icon and then click the :guilabel:`Compile` button for your contract.

Expand Down

0 comments on commit 18e9b75

Please sign in to comment.