Npm ��������� kali linux

Как установить Node.js в Kali Linux

Получение программного обеспечения непосредственно из исходного кода является обычной процедурой на компьютерах Unix и обычно включает в себя следующие три шага: настройка make-файла, компиляция кода и, наконец, установка исполняемого файла в стандартные места. Чтобы работать с Node.js в Kali Linux, рекомендуется следовать упомянутому процессу, поскольку это проще, чем другие решения.

Хотя Python предпочтительнее при работе с Kali Linux, оба языка программирования (Python и JavaScript) имеют одинаковые конечные цели. Не существует правильного или неправильного решения о том, какая платформа вам больше всего подходит, поэтому, если вы хотите работать с JavaScript вместо Python, не расстраивайтесь из-за этого. Кроме того, Node может использоваться в широком диапазоне модулей, что означает, что вы можете использовать Python в своем приложении Node.JS и наоборот.

Давайте начнем с установки!

Важный

«Зачем мне создавать свой собственный .deb of Node, если я могу скачать его с сайта? — вот что за глупость …». Как вы знаете, Kali Linux не является нормальным дистрибутивом Linux, поэтому доступный публично доступный пакет на веб-сайте Node может работать на нем некорректно. Вы можете попробовать его, если хотите, но для гарантии правильной работы просто следуйте этим шагам, и у вас не должно возникнуть проблем позже.

1. Убедитесь, что у вас есть все необходимые инструменты

Чтобы создать свой собственный пакет .deb для Node, вам понадобится python и компилятор c ++ «g ++». Выполните следующую команду для установки необходимых инструментов (если они уже установлены, их следует только обновить):

Заметка

Вы можете получить предупреждение типа «dpkg был прерван, вы должны запустить вручную» sudo dpkg —configure -a «исправить проблему». Вам просто нужно, как уже упоминалось, выполнить sudo dpkg —configure -a чтобы решить ее, а затем снова выполнить команду.

2. Создайте временную папку

Вы должны создать временную папку для создания пакета .deb Node.js. Вы можете создать его с помощью mktemp, чтобы сделать его одной командой, выполнив следующую инструкцию:

-d Аргумент указывает, что mktemp должен создать каталог вместо файла. В этой команде мы создаем переменную, которая содержит сгенерированный временный путь с помощью mktemp, а затем переключаемся на этот каталог в терминале.

3. Загрузите и распакуйте Node.js

Загрузите распространяемый код Node.js, выполнив в терминале следующую команду:

После завершения загрузки извлеките содержимое файла tar с помощью следующей команды:

Это должно создать папку с префиксом node-v это зависит от загруженной версии Node.js.

4. Запустите скрипт настройки

Скрипт конфигурирования — это исполняемый скрипт, предназначенный для помощи в разработке программы, которая будет запускаться на большом количестве разных компьютеров. Он сопоставляет библиотеки на компьютере пользователя с библиотеками, которые требуются программе перед компиляцией из исходного кода. Запустите скрипт настройки с помощью следующей команды:

5. Создайте Node .deb пакет, компилирующий код

Для создания нашего устанавливаемого пакета Node.js мы будем использовать для него CheckInstall. CheckInstall отслеживает все файлы, созданные или измененные вашим установочным скриптом, и создает стандартный двоичный пакет (.deb, .rpm, .tgz). CheckInstall действительно полезен, если у вас есть архив с программным обеспечением, которое вы должны скомпилировать (именно то, что мы делаем в данный момент).

Для создания пакета Node.js выполните следующую команду:

Обратите внимание, что для большинства полезных действий checkinstall должен запускаться от имени пользователя root. Мы будем использовать fakeroot, потому что, как вы, возможно, знаете, по соображениям безопасности рекомендуется избегать выполнения от имени пользователя root всего, что может быть сделано обычным пользователем, даже если вы можете запускать sudo, потому что это ваша машина.

Команда должна начать компилировать Node.js, и это займет некоторое время, так что расслабьтесь, получите колу и подождите.

6. Установите Node сгенерированный пакет

Как только пакет скомпилирован, в выходных данных предыдущего шага вы должны получить сообщение, в котором указано имя сгенерированного пакета .deb:

В этом случае название нашего пакета node_7.7.2-1_amd64.deb Теперь нам просто нужно установить его, используя dpkg, выполнив следующую команду:

Читайте также:  Canon canoscan lide 120 драйвера windows 10

Заметка

Не забудьте заменить значение i аргумент с именем сгенерированного пакета в предыдущем шаге.

Источник

Installing NodeJs and NPM – Kali/Ubuntu

Recent Comments

Categories

What are NodeJs & NPM

NodeJs to put it simply is an open-source, cross-platform runtime environment for developing server-side web application.

Npm is the a package manager for javascript using to install and run things Such as Grunt

For more information on NodeJs or NPM follow the links in the more reading section of this post.

How to install using git

I usually find the easiest way to install both NodeJs and NPM on linux systems is straight from git. It provides the latest version and allows for patches to node and npm to be updated using pull requests and more from git, either way that’s out of scope for this tutorial so keeping it simple.

Open up a terminal and type the following

# Make our directory to keep it all in

# Add the location to our path so that we can call it with bash

echo ‘export PATH=$HOME/local/bin:$PATH’ >>

Now we can start with downloading and compiling

git clone git://github.com/nodejs/node.git

cd node

./configure –-prefix=

make install

Now NPM (Node Package Manager)

git clone git://github.com/npm/npm.git

cd npm

make install

and that’s it we are done . . .

Testing our installation

Open up a command prompt and type

Both should return a version number at the time of writing this I got npm v3.5.4 and NodeJs v6.0.0-pre

Источник

How to install Node.js in Kali Linux

Read this article in other language

Obtaining software directly from the source code is a common procedure on Unix computers, and generally involves the following three steps: configuring the makefile, compiling the code, and finally installing the executable to standard locations. In order to work with Node.js in Kali Linux, it’s recommendable to follow the mentioned process as it’s easier than other solutions.

Although Python is prefered when working with Kali Linux, both of the programming languages (Python and JavaScript) have the same end goals. There is no right or wrong decision for adopting which platform is best suited to you, therefore if you want to work with JavaScript instead of Python don’t feel bad about that. Besides, Node can be utilized in the broad range of modules, that means that you can use Python in your Node.JS application and viceversa.

Let’s get started with the installation !

Important

«Why should i create my own .deb of Node if i can download it from the website ? ñee, what a stupid post . » . As you know, Kali Linux is not a normal Linux distribution, therefore the available package publicly in the Node website may not work properly on it. You can try it it if you want, but to guarantee a correct functionality, just follow these steps and you should not have problems later.

1. Verify that you have all the required tools

To create your own .deb package of Node, you will need python and the compiler of c++ «g++». Execute the following command to install the required tools (if they’re already installed they should be only updated):

You may get a warning like «dpkg was interrupted, you must manually run ‘ sudo dpkg —configure -a ‘ to correct the problem». You just need, as mentioned, execute sudo dpkg —configure -a to solve it and then proceed with the command again.

Besides, if you are unable to install the checkinstall package (happens usually on recent installations of Kali Linux), proceed with the fix mentioned in this article in order to install the package correctly.

2. Create a temporary folder

You should create a temporary folder to generate the .deb package of Node.js. You can create it using mktemp, to make it with a single command execute the following instruction:

The -d argument indicates that mktemp should make a directory instead of a file. In this command we are creating a variable that contains the generated temporary path by mktemp and then switching to that directory in the terminal.

3. Download and extract Node.js

Download the distributable code of Node.js executing the following command in the terminal:

Once the download finishes, extract the content of the tar file with the following command:

This should create a folder with the preffix node-v that will vary according to the downloaded version of Node.js.

4. Run configure script

A configure script is an executable script designed to aid in developing a program to be run on a wide number of different computers. It matches the libraries on the user’s computer, with those required by the program before compiling it from its source code. Run the configure script with the following command:

Читайте также:  Windows не может установить mouse что это

5. Create Node .deb package compiling the code

To create our installable package of Node.js we are going to use CheckInstall for it. CheckInstall keeps track of all the files created or modified by your installation script and builds a standard binary package (.deb, .rpm, .tgz). CheckInstall is really useful if you’ve got a tarball with software that you have to compile (exactly what we’re doing in this moment).

To create the package of Node.js execute the following command:

Note that for most useful actions, checkinstall must be run as root. We’ll use fakeroot because as you may know, for security reason, it is a good idea to avoid doing as root everything that could be done as normal user, even if you can run sudo because it is your machine.

The command should start to compile Node.js and it will take a while, so relax, get a cola and wait.

6. Install Node generated package

Once the package is compiled, in the output of the previous step, you should receive a message that specifies the name of the generated .deb package:

In this case, the name of our package is node_7.7.2-1_amd64.deb , now we just need to install it using dpkg executing the following command:

Remember to replace the value of the i argument with the name of the generated package in the previous step.

Источник

Zenmap — Easy GUI version of Nmap

Zenmap is Graphical User Interface (GUI) version of Nmap. Zenmap is also very powerful tool like nmap. For it’s graphical interface and easy menus makes it very easy to use.

Installing Zenmap on Kali Linux 2021

To install Zenmap we need to download it from Nmap’s official website. On the website we can download Zenmap rpm file, or we can click here to directly download it.

On the download screen we can click to save it as we did in the following screenshot.

This a a very small file (approximately 700kb) to download, download will finish in some seconds.

After downloading it we can open our terminal and run following command to update our system:

This may ask for root password. After finishing the update we need alien. Alien means not 👽👾 (the creatures from other planet). Alien is a program that can converts an RPM package (RedHat) file into a Debian package file.

This is not a standard way to install software packages on Debian based distribution. But in this case we need to do this.

We can install alien by using following command:

Then the alien will be installed as we can see on the following screenshot:

Then we need to navigate to our Downloads directory where we have the downloaded Zenmap rpm file.

Then we need to convert our downloaded rpm file to deb file using alien by using following command:

This command will convert zenmap rpm file to zenmap deb file. As we can see in the following screenshot:

Now we can install it on our system by running following command:

After applying the above command Zenmap will be installed as we can see in the following screenshot:

Zenmap uses Python GTK for creating a graphical user interface, that’s why we have to install that as well on our Kali Linux system.

We need to download it from Ubuntu’s website and install it. To download it we use following command:

Then we install it by using following command:

Now we can search for Zenmap on our application menu or we can run zenmap or sudo zenmap command on our terminal to open Zenmap.

Using Zenmap on Kali Linux

After a successful installation we can use Zenmap. If we use Zenmap with root then we can use it’s all options. So we open it with root by using following command:

We can see that Zenmap is opened on the following screenshot:

Here everything is very easy. Here we need to put the IP address of our target network. For an example we are choosing our localhost system’s IP address (192.168.122.148), we also can choose the website’s address.

Then we need to choose the profile as «Quick Scan«. For an example we have chosen «Quick Scan» we can choose other profiles as per our requirements. Then we just need to click on «Scan». Then the result will comes in front of us as the following screenshot:

Читайте также:  Переключение рабочих столов windows 10 горячими клавишами

In the above screenshot we can see the open ports on our target.

Once the scan has completed, we can click on each tab to get further details about our target. If we’re performing a scan on an entire network, the «Topology» tab will help us create a network diagram of the target network.

Zenmap is very easy to use and user-friendly. This is how we can install Zenmap on Kali Linux new versions and it’s uses.

Liked our article? Then make sure to follow our mail-subscription to get new articles directly on inbox. We also update articles on our Twitter and GitHub profiles. Make sure to follow us there. We also have Telegram group for chatting with everyone.

For any kind of problem and queries make sure to comment in the comment section. We always reply.

You may like these posts

Comments

root@kali /h/e/Downloads# python /usr/bin/zenmap
File «/usr/bin/zenmap», line 114
except ImportError, e:
^
SyntaxError: invalid syntax
root@kali /h/e/Downloads# python2 /usr/bin/zenmap
Could not import the zenmapGUI.App module: ‘No module named gtk’.
I checked in these directories:
/usr/bin
/home/ezri/Remarkable/remarkable
/home/ezri/Remarkable/remarkable_lib
/usr/lib/python2.7
/usr/lib/python2.7/plat-x86_64-linux-gnu
/usr/lib/python2.7/lib-tk
/usr/lib/python2.7/lib-old
/usr/lib/python2.7/lib-dynload
/usr/local/lib/python2.7/dist-packages
/usr/local/lib/python2.7/dist-packages/LinkFinder-1.0-py2.7.egg
/usr/local/lib/python2.7/dist-packages/EditorConfig-0.12.2-py2.7.egg
/usr/local/lib/python2.7/dist-packages/py_altdns-1.0.0-py2.7.egg
/usr/local/lib/python2.7/dist-packages/termcolor-1.1.0-py2.7.egg
/usr/local/lib/python2.7/dist-packages/dnspython-2.0.0-py2.7.egg
/usr/local/lib/python2.7/dist-packages/requests_file-1.5.1-py2.7.egg
/usr/local/lib/python2.7/dist-packages/idna-2.10-py2.7.egg
/usr/local/lib/python2.7/dist-packages/urllib3-1.25.10-py2.7.egg
/usr/local/lib/python2.7/dist-packages/certifi-2020.6.20-py2.7.egg
/usr/local/lib/python2.7/dist-packages/shodan-1.23.0-py2.7.egg
/usr/local/lib/python2.7/dist-packages/ipaddress-1.0.23-py2.7.egg
/usr/local/lib/python2.7/dist-packages/click_plugins-1.1.1-py2.7.egg
/usr/lib/python2.7/dist-packages
/usr/lib/python2.6/site-packages
If you installed Zenmap in another directory, you may have to add the
modules directory to the PYTHONPATH environment variable.

Your problem solved here .

python3 /usr/bin/zenmap
File «/usr/bin/zenmap», line 114
except ImportError, e:
^
SyntaxError: invalid syntax

Please check the updated article. Thanks

Hello I want to hack someone’s WhatsApp

This will be illegal. Sorry we can’t lead you in this matter.

I have same problem even though i followed all your instructions it has the same error: If you installed Zenmap in another directory, you may have to add the
modules directory to the PYTHONPATH environment variable.

It seems to happen with the latest kali linux version.

Also when i try to install python as you show in your steps, i get this error:
Note, selecting ‘python-gtk2’ instead of ‘./python-gtk2_2.24.0-5.1ubuntu2_amd64.deb’
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
python-gtk2 : Depends: python-cairo (>= 1.0.2-1.1) but it is not installable
Depends: python-gobject-2 (>= 2.21.3) but it is not installable
E: Unable to correct problems, you have held broken packages.

Have you tried
sudo dkpg -i —force-all nameofpackage.deb

March 2021, I sadly get this error both on the newest version and the older one.

sudo dpkg -i zenmap_7.91-1_all.deb
dpkg: warning: parsing file ‘/var/lib/dpkg/tmp.ci/control’ near line 7 package ‘zenmap’:
‘Depends’ field, reference to ‘rpmlib’:
«implicit exact match on version number, suggest using ‘=’ instead
dpkg: error processing archive zenmap_7.91-1_all.deb (—install):
parsing file ‘/var/lib/dpkg/tmp.ci/control’ near line 7 package ‘zenmap’:
‘Depends’ field, reference to ‘rpmlib’: version ‘PartialHardlinkSets’: version number does not start with digit
Errors were encountered while processing:
zenmap_7.91-1_all.deb»

Something with me missing rpmlib? Too n00b to totally understand sorry.

Thanks for all your hard work.

This problem is very similar to this

Using the newest Desktop Windows 10, version of Kali Linux, March 2021, on Oracle Vm.

Alien is giving me an Error 25 on VirtualBox 6.1. Please help.

Package build failed. Here’s the log:
dh
dh: error: specify a sequence to run
make: *** [debian/rules:7: binary] Error 25

Thank you in advance.

We can install it without converting try following command:

sudo alien -i zenmap*.rpm

Try it and tell if it working or not in your system.

──(root��kali)-[/home/kali/Downloads]
└─# apt install ./python-gtk2_2.24.0-5.1ubuntu2_amd64.deb
Reading package lists. Done
Building dependency tree. Done
Reading state information. Done
Note, selecting ‘python-gtk2’ instead of ‘./python-gtk2_2.24.0-5.1ubuntu2_amd64.deb’
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
python-gtk2 : Depends: python-cairo (>= 1.0.2-1.1) but it is not installable
Depends: python-gobject-2 (>= 2.21.3) but it is not installable
E: Unable to correct problems, you have held broken packages.

You already wrote the solutions. try the unmet dependencies which are not installed. Install them first.

Post a Comment

Please do not spam here. It is comment box not a spambox. Promotional links are not allowed.

Источник

Оцените статью