aboutsummaryrefslogtreecommitdiffstats
path: root/docs
diff options
context:
space:
mode:
authorAlex Beregszaszi <alex@rtfs.hu>2017-04-19 23:59:03 +0800
committerAlex Beregszaszi <alex@rtfs.hu>2017-04-20 22:39:30 +0800
commit8bf842050e83c33ad08789219ea62b8ace33de88 (patch)
tree6b020efbafd4f806098203a46b673060c95902e7 /docs
parent3cacea74c9589b70fffd0ec620c21043742ceb26 (diff)
downloaddexon-solidity-8bf842050e83c33ad08789219ea62b8ace33de88.tar.gz
dexon-solidity-8bf842050e83c33ad08789219ea62b8ace33de88.tar.zst
dexon-solidity-8bf842050e83c33ad08789219ea62b8ace33de88.zip
Support --allow-paths in the CLI
Diffstat (limited to 'docs')
-rw-r--r--docs/using-the-compiler.rst2
1 files changed, 2 insertions, 0 deletions
diff --git a/docs/using-the-compiler.rst b/docs/using-the-compiler.rst
index e1c63265..1cc1f2b8 100644
--- a/docs/using-the-compiler.rst
+++ b/docs/using-the-compiler.rst
@@ -29,6 +29,8 @@ files reside, so things like ``import "/etc/passwd";`` only work if you add ``=/
If there are multiple matches due to remappings, the one with the longest common prefix is selected.
+For security reasons the compiler has restrictions what directories it can access. Paths (and their subdirectories) of source files specified on the commandline and paths defined by remappings are allowed for import statements, but everything else is rejected. Additional paths (and their subdirectories) can be allowed via the ``--allow-paths /sample/path,/another/sample/path`` switch.
+
If your contracts use :ref:`libraries <libraries>`, you will notice that the bytecode contains substrings of the form ``__LibraryName______``. You can use ``solc`` as a linker meaning that it will insert the library addresses for you at those points:
Either add ``--libraries "Math:0x12345678901234567890 Heap:0xabcdef0123456"`` to your command to provide an address for each library or store the string in a file (one library per line) and run ``solc`` using ``--libraries fileName``.