Linux - SecurityThis forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I have a question for anyone? I am not sure how to do this but
I want to be able to use a static connection but if my ISP provides DHCP do I have to use that? I guess what I'm saying is am I forced to use DHCP?
I know it's probably a stupid question but I need to know for security reasons.
I am using DHCP now and am wondering if it would be better for me to use static connection? Or would that upset my IP?
Depending on the way your ISP has things set up on their end, you might be able to get away with statically assigning an IP which you know would have been dynamically assigned to you. That said, things could change any moment and you could be left without a working connection.
Quote:
Originally Posted by penguinista
I know it's probably a stupid question but I need to know for security reasons.
Yeah, DHCP means your machine sends a request to the server (asks for a free ip address), and the server then responds by telling which IP address you can use. Dynamic means it can change, it's not same all the time -- altough the servers usually (at least those I've faced) tend to assign you the same IP if it's available that you used last time, and if it's not, then assign a new one. A static ip usually means extra payment, because it would enable you to refer to your machine (for example connect to a service on your machine, like ssh or http) easily with an ip address that would always be the same. Dynamic ip works too, but since it may change each time you reconnect, it may not be the same always, and that makes connecting to your machine's services more difficult - you need to know the current ip all the time Though a static ip doesn't mean you can run a webserver on your machine, some (many) ISPs deny you that unless you pay them extra again.
I don't see the security aspect here, could you clarify? For me a dynamic ip would be more "secure", because it changes. Nevertheless the information is always at the server, and can easily be logged, so even if you used static or dynamic ip, it wouldn't be any more or less secure. If you want to refer to your own machine (from the machine itself), you don't need a static ip, there's the loopback device which is 127.0.0.1. From outside there's no difference if the ip of your machine is static or dynamic, except that it either is or is not the same all the time.
Trying to use a static IP won't "upset the ISP"--it just won't work.
That's not an entirely accurate statement. I've actually done this myself several times in the past and I can assure you it did work. Keep in mind that even if one has a DHCP-assigned address, that doesn't necessarily mean your IP is gonna be changing very often. I've had boxes where the DHCP-assigned IP has remained the same for well over a year. As I said, it all depends on how your ISP has things set up. Indeed, on some ISPs (perhaps even most - I don't know) it "won't work" as they can have, for example, a setup where if your IP doesn't appear as having been actually leased to you, it won't get routed. So in cases such as that you will of course have to use DHCP by force. But whether or not (and for how long) a staticly set IP will work in the OP's case can only be determined by him through trial and error.
EDIT: Just to be clear: I am not recommending that this be done. I'm basically just saying that it's technically possible for it to be done in some cases. My general recommendation is that if the OP needs a static IP, then a static IP should be purchased. I can't really be any more specific because, just like you guys, I have no idea what the OP is trying to achieve with this and I also don't know what security implications he is referring to.
Sorry guys! I just was wondering whether or not DHCP is more secure than
static IP? That's all - I should have been more clear.
Thank you all for your help,
Penguinista
I don't know why there would be a security difference.
For win32sux;
Yes, you can in fact set the static IP to the one assigned by DHCP. For the reasons you state, it is fragile. I obviously should have said something like "won't work reliably "
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.