E
E
Eugene2020-01-08 08:21:24
PHP
Eugene, 2020-01-08 08:21:24

Is it safe to pass your ip to communicate with ftp?

The situation is this: the hosting support service writes to me that in order for me to work with the site directory via ftp, I need to give them my IP, and then they will bind it and I will have access to ftp in the browser. Is it safe to share your IP at all?

Answer the question

In order to leave comments, you need to log in

4 answer(s)
A
aRegius, 2019-03-16
@aRegius

It's not entirely clear how it works

# Исходный словарь
>>> prefs = {'person1': {'item1': 5, 'item3': 10},
             'person2': {'item1': 3, 'item2': 6}}
# Обращение к значению ключа вложенного словаря
>>> prefs['person1']['item1']
5
# Разница значений ключей
>>> prefs['person1']['item1'] - prefs['person2']['item1']
2
# Функция pow() возведения числа в степень 
>>> pow(5, 2)
25
>>> pow(5, 2) == 5 ** 2
True
# Перебираем ключи словаря
>>> [key for key in prefs['person1']]
['item1', 'item3']
>>> [key for key in prefs['person2']]
['item1', 'item2']
# Находим общие для словарей prefs['person1'] и prefs['person2'] ключи
>>> [key for key in prefs['person1'] if key in prefs['person2']]
['item1']
# Функция sum() нахождения суммы
>>> x = list(range(5))
>>> x
[0, 1, 2, 3, 4]
>>> sum(x)
10

PS I won’t translate into PHP, it’s out of my competence)

V
Vladimir Korotenko, 2020-01-08
@toohappy

It is safe, only all normal hostings have a control panel where you assign IPs yourself, add new ones, and inside the virtual machine you yourself raise the necessary services.

A
Alexander, 2020-01-08
@NeiroNx

And you have no choice. And secondly, if it changes, it will be even more fun.

K
Karpion, 2020-01-16
@Karpion

Absolutely safe.
But if you access the Internet from under NAT, then you need to transfer the IP address of the NAT server.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question