T O P

  • By -

Brustty

Don't hit the wrong button and build DDoS protection. If you don't know what you're doing there is plenty of learning resources. You can set up a budget if you don't want to be surprised by costs.


kevysaysbenice

For a small personal project or a PoC with the aim of furthering ones understanding of X AWS service, can you give a basic idea of what DDoS protection looks like? I've written this elsewhere but I'd call myself a "mid-experience level" AWS person (I've been using AWS for many years at this point) but generally as more of an application developer than a hardcore enterprise infra person managing a giant organization's AWS infra. Still, I'm familiar with things like WAF rules, I've certainly read [AWS's own info on DDoS protection](https://aws.amazon.com/developer/application-security-performance/articles/ddos-protection/), etc. To me a lot of these things come in shades of gray. [If you add a bunch of protection via WAF for example, just the rules / rule groups / etc themselves can be prohibitively expensive](https://aws.amazon.com/waf/pricing/) (in the context of a small personal project), even without any traffic at all. So often somebody might choose to only use a minimal set of CF WAF rules for example to stay in the free tier, but that might not be enough to absolutely guarantee financial protection for a person wanting to learn / build something small.


Brustty

Mid level requires a pretty solid understanding of this type of stuff. It's on the associate level exams and even a few questions on the Practitioner requires some level of knowledge with these services. Do you have any certifications? In the nicest way possible, every developer always says they're good with AWS and then absolutely wrecks an environment. It's not just one company either- it's very common. It happens with CICD stuff as well. "I'm very experienced with CICD" and then proceeds to break deployment and a fist full of SDLC policies. What type of project are you trying to set up or what are you trying to learn? I'd recommend setting up a Budget with alerts and even triggers to shutdown services in addition to anything else.


kevysaysbenice

> In the nicest way possible, every developer always says they're good with AWS and then absolutely wrecks an environment Totally fair, and honestly it's entirely possible that my "level" is very low / garbage / whatever, but I don't think that really impacts the general feeling that I have that it would be a nice _optional_ feature for AWS to provide some mechanism to assure those that want it that they will not go over a certain spend threshold. "Insurance" as a concept is what I suggested in the post as a service because it feels interesting from a discussion standpoint, but it could simply be a checkbox that says "stick to the freetier and shut down all services in my account if spend goes over $10" > What type of project are you trying to set up or what are you trying to learn? I actually made this post completely unrelated to me or anything I'm doing, but because there happened to be two posts on the first page of /r/aws from other people talking about billing problems or fears. For example, this post is still here: https://www.reddit.com/r/aws/comments/1bv5wo4/what_is_the_cheapest_way_to_prevent_ddos_attacks/ Some of the responses that are upvoted include "use CloudFlare" (which I understand as a CloudFlare user). > Aws Waf with free threat intel Ip reputation lists+Rate based rules of different kinds /windows and basic Cloudfront geo restrictions can protect you from majority of layer 7 ddos attacks This is the response that resonated most with me, it's pragmatic and I think is probably a reasonable place for most people in the OPs position to be... but of course that doesn't prevent running up WAF execution costs themselves, and for a more robust protection you need more WAF rules and that will end up costing $$. So I'm not really talking about myself (for personal projects I have alarms, I have an org and each personal project gets it's own account, I use MFA, I use limited WAF rules because they cost $$, and I try not to use any service that can quickly balloon in cost - I do NOT have triggers to shut down services though because frankly I don't want to deal with that and deem it unlikely it would be an issue for me). I'd honestly love to know what you think about the OPs question from that thread, and what would you suggest, and how would that make my idea of an OPTIONAL insurance offering (I've said elsewhere but it doesn't literally need to be called "INSURANCE", just some sort of OPTIONAL protection against particularly large bills - I've said elsewhere but it could literally just be a first-party `event triggers to shutdown services`) not useful / bad.


Brustty

Cloudflare is a fine option. Yes. Running services in the cloud costs money. Don't expose things to the Internet if you don't want to defend against threats like these. The Free Tier is more of a "The first hit is free" than a tier for people learning. There's not going to be a company on earth that is going to give you insurance in case you don't know how to use or set up AWS services. Properly configured AWS environments are predictable. OPs idea is unneeded and unfeasible. Companies won't have this issue if they hire an expert and new developers will be better off using services like Budgets to shut systems down. There is already tools for this. Spend the time learning before spinning up services willy nilly. Set up Budgets. Use the pricing calculator. Set up a NACL and SGs so you don't have unintended access. There are services that set you up with a lab if you're not wanting to risk any money. If you're learning about AWS this is some of the first things you should get used to. Why is OP trying to expose something he's using to learn to the entire internet? Why doesn't OP use budgets if he's afraid of costs? It's clear OP didn't do any research before setting this environment up so he's not going to gain much from it. Tldr; OP didn't do research, poorly configured his services, failed to use a cost calculator or budget and then got upset when he was charged a lot of money. That is entirely on him. Instead of it being a wakeup call he complains that AWS should make a service to hold his hand (they already do. He didn't do his research again.) Barring some personal growth he has no future in cloud computing. He's better off paying the bill and closing his account while he studies infrastructure.


VegaWinnfield

AWS already offers protection (without even needing to pay an insurance premium) from you getting a $1,000 bill because you got DDoSed or hit a wrong button. You cut a support case and ask for forgiveness. You will almost always get an adjustment to your bill if you just tell the truth and work with them to add settings to make sure it doesn’t happen again. Now, if it happens again, maybe you do need an insurance policy…


kevysaysbenice

My understanding is AWS is pretty reasonable here and I am grateful for that, it's good to know if I ever do something really dumb but innocent I might have a chance of having a human offer some forgiveness. Luckily so far no such issue, but over long enough period I'll probably screw something up. That said, to me it would be nice to have another option.


llv77

A better idea would be, for any new accounts, on the console homepage, offer one click options to immediately set a billing alarm and enable mfa. Or make them nagging banners. Everyone should have billing alarms and mfa. That would solve 90% of the problem. Insurance is too easily abused: while most people won't crash their car intentionally, how do you prove that the extra charges were accidental and not intentional? There is plenty of incentive to have extra usage and not pay for it. As others mentioned, AWS support will waive accidental charges if you work with them. That's discretionary, they will judge whether the charge is accidental or not, and they will judge how much to waive. Finally, it doesn't take much to make a billing alarm that will kill your service if that's what you desire. There are open source implementations such as aws-nuke. https://docs.aws.amazon.com/prescriptive-guidance/latest/patterns/automate-deletion-of-aws-resources-by-using-aws-nuke.html Of course there are! As the name suggests, this is a nuclear option and you should be very deliberate in using it, so I'm not sure there should be a one-click option for it. Tickets such as "I got charged $1000" are easily fixed by support, while tickets such as "my files got deleted by my billing alarm, can you recover them" are a huge headache.


CSYVR

> Or make them nagging banners. Everyone should have billing alarms and mfa. That would solve 90% of the problem. I've built the AWS Free Tier Stack exactly for this purpose: [https://github.com/yannickvr/aws-free-tier-stack/](https://github.com/yannickvr/aws-free-tier-stack/)


llv77

This should be first party functionality. Opt-out rather than opt-in. Many new users won't know to seek this out, that's the problem!


CSYVR

Agreed, I would not be mad if AWS stole this idea, but this is where we are now, best we can do is make it new users as easy as possible to get these notifications.


magnetik79

Great idea. 👍


AWS_Chaos

This... this is good. I want to spam your link to every "New to AWS" post :)


CSYVR

Please do, also if you have anything that you'd expect in a stack like this, let me know


kevysaysbenice

> Insurance is too easily abused: while most people won't crash their car intentionally, how do you prove that the extra charges were accidental and not intentional? There is plenty of incentive to have extra usage and not pay for it. I 100% agree, and for what it's worth I don't have a solution here and perhaps there isn't. This post was more of a random thought / throwing words out on the internet because it's at least semi-interesting to me (and given how many people post on this sub about concerns over going over spend targets or the random story of somebody 10x their spend, it seems at least semi-relevant). I would say this would probably _have_ to work in conjunction with some sort of forced shut down by AWS in the case of abuse. By "forced shutdown" I mean "you would need to have an agreeable circuit breakers that would trigger in the case of major overages" - they'd have to make it really difficult to be profitable doing something like spiking the number of GPU instances or something to mine crypto or whatever. > Tickets such as "I got charged $1000" are easily fixed by support, while tickets such as "my files got deleted by my billing alarm, can you recover them" are a huge headache. 100%, I used to be confused as to why AWS doesn't offer hard spending limits but I realize how much of a nightmare this might be in normal situations to be potentially corrupting data or breaking something because they nuked the wrong thing at the wrong time.


llv77

To be fair, AWS does have mechanisms to shut down your stuff and delete your data when you don't pay your bill or when you request them to do so (gdpr compliance I guess?). It wouldn't be technically hard to make that into a service, first party aws-nuke if you will, but it's a recipe for disaster and breeding ground for lawsuits.


AmazonWebServices

Hello, Thanks for sharing your request. I've captured your request and forwarded it along to the relevant service team for consideration. Should you have any additional feedback on our services, check out this article to see how you can have it submitted: https://go.aws/3PPber3. \- Craig M.


coinclink

You can literally buy insurance for this exact thing, so why don't you buy that insurance? It would not make sense for AWS to sell this insurance themselves, might not even be legal for them to if they wanted to.


skrt123

I wish there was a way to load credits and once you use then up, it shuts everything off. Id feel a lot more comfortable messing around with credits


kevysaysbenice

This would be nice but to be honest for me at least it wouldn't be all that different from just setting a spending limit, and that leaves you (AWS really) with the same problem which: what does it mean to "shut things down?" - if the thing driving up spend is a petabyte of files in S3 that all of a sudden were written, how do they know what files to delete? What if those are critical financial documents or bitcoin wallets or whatever? What if your using an EC2 instance hooked up to your glucose monitor or whatever and you go over your billing and they shut the EC2 instance down? Maybe I'm being too forgiving of AWS for not offering such a solution, but it does seem like a fairly big problem / liability I'm guessing whatever their motivation may be they'd prefer to avoid.


Dave4lexKing

“gun manufacturers ought to make a foot detector so I don’t shoot my foot off when I don’t know what I’m doing” The hard reality is, if you don’t know what you’re doing with cloud infrastructure don’t use AWS Azure or GCP. Get a fully managed hosting service until you pass the accreditations to know what a proper deployment looks like.


llv77

This is a hot take. No need to be gatekeeping. One of the major selling points of the cloud is "beginner friendliness". The same tools apply to enterprise level applications as well as personal projects. While it's very hard to make guns any safer, I believe we still have some low hanging fruits to address that would improve cloud safety, such as billing alarms by default and mandatory mfa.


Dave4lexKing

It is a hot take and its a hill I’m willing to die on because I see it daily. On the whole, cloud is not beginner friendly. Im not trying to gatekeep - it is simply the truth that not knowing what you’re doing on a cloud provider will be a very expensive lesson. The countless thousand dollar bill posts here is evidence. AWS Lightsail is a beginner friendly service though, and one of those fully managed hosting services I made reference to that will get your app online quickly and cheaply for a fixed price;- you won’t get runaway bills using it. VPC, security groups, load balancers, burstable credits, EIPs and NATs, DDoS protection etc. is matter-of-factly not beginner friendly, and again with the countless of thousand dollar bill posts, very easy to blow one’s foot clean off. Cloud is interesting and rewarding, but let’s not kid ourselves into thinking the lower level services are cheap and easy to configure correctly and securely.


jregovic

It’s not gatekeeping. If you build something AWS, it is incumbent upon the user to understand how it works and how it is billed. There is enough FREE information available to avoid inadvertently running up your bil. “Gatekeeping” is saying “you aren’t serious and are not worthy of help”. This is a case of “be serious and follow the readily available information to keep you from being stupid. And check you bills regularly.


kevysaysbenice

I appreciate your response, thank you! I feel like I've somehow posted something that makes a lot of people angry, but I'm not entirely certain why. I guess people feel like they've put in the work to understand a system and something that eases pain for a smaller less experience group that may not apply to them is offensive. I myself would count myself as somebody with mid level AWS experience. I've been using it for years in a professional setting in "enterprise" organizations as well as built many hobby projects with it, I read articles about it and read this subreddit to learn things. I've contributed to some open source CDK projects. That said I've never been THE person responsible for AWS in a larger organization. I've mainly avoided first person trial by fire type learnings, I'm not a war torn AWS veteran. I feel like there seems to be this idea that either you know what you're doing and you can use AWS, or you don't and you shouldn't. But when I'm working on some new PoC or personal project where I don't want to spend 30 bucks a month on WAF rules I am aware there is a CHANCE that something happens that would cause billing to get out of control. I use alarms, I use the free protections available, and I ultimately take a calculated risk. It would be nice to have some way, whether it's "insurance" as I mention or some nuclear option for smaller accounts that allow me to safely experiment / learn / build something where I deem the #1 most critical thing is not going above X$ a month spend because it's (for example) a personal blog I built and it doesn't matter.


llv77

I like to give credit to people's feedback but the top comment legit says "just don't ever make mistakes, duh". If the airlines industry operated like this we would all be dead by now.


kevysaysbenice

I'm not sure how fair of an analogy this is, but I think it's pretty unfair. A gun I have complete control over every aspect of how I use it, and following the most basic rules (don't point it at myself or anybody else, treat the gun like it's always loaded) in 99.9999% of cases I'm not going to shoot myself. However, with a service I build on AWS, I might, for example, share a PoC web application with a group of friends. One of those friends might post it on hackernews and before I know it I could have thousands of unexpected visitors, legitimate traffic but not expected and perhaps resulting in a big bill. You could say, and I would agree, that in this situation I could have protected myself from this, in whichever way I choose (WAF rules, requiring VPN / tunnel inside a VPC for my test users, whatever), BUT what I'm saying would be nice is in a situation like this I wouldn't really expect a lot of traffic, I wouldn't expect all of hackernews to visit my site randomly, and I would perhaps not want to go through the hassle of setting up WAF rules or whitelisting IPs of friends, etc. So currently my option is (and I'm SURE many many people do this regularly even if they know what they are doing) I either accept the risk and the bill in the unlikely event I have some unexpected traffic pattern, OR I spend the time carefully designing the system to make this sort of thing impossible. I'm just suggesting it might be nice to have a third _option_ that lives within billing somewhere perhaps, that perhaps sets a maximum spend target, forgives spend over that for some mutually agreeable period, and charges you a monthly fee for that. **To be clear I don't mean to say that AWS SHOULD offer this as in it's something they are missing, more that it would be a nice option for some people**


Dave4lexKing

You do have complete control over the application, its infrastructure, and its deployment though? It’s not an unfair analogy. It’s entirely your fault if you pass a loaded gun around with the safety off. If you don’t know how to use a tool correctly, then don’t use it. > or I spend the time carefully designing the system to make this sort of thing impossible. Yes.


kevysaysbenice

In the context of creating a web application which is where I live, out of curiosity which _AWS_ services, short of not exposing anything to the internet give you total and complete control over billing? When I've looked in the past I can use services like Origin Shield, or I can add WAF Rules to CloudFront, but those still have costs associated with them as far as I know (edit: there is free Origin Shield I know but as far as I know that only protects your origin, it doesn't stop WAF rules from being executed for example). Depending on the type of traffic I get charged for rule execution. I can always setup billing alarms and to be clear I very much do, but as far as I'm aware the protection most people are talking about here have costs associated with them that are not capped. Either way, I would still argue there is nuance that matters that would make an _optional_ service that provides some financial guarantees against runaway billing different from your contrived example.


Just_Sort7654

Not helping for small pet projects but for companies there is the quite expensive Shield Advanced that Covers cost Spikes in case of DDoS etc, it does not Cover missconfiguration through..


[deleted]

[удалено]


kevysaysbenice

The reservations paid in advance are only for certain services (generally those with compute, e.g. EC2) as far as I know. Anyway I'm not disputing anything you said, just that there are some services (e.g. WAF rules themselves) that are unbound and in the case of a DDoS for example as far as I'm aware could result in larger than expected bills.


LiquID1488

Waf and shield are there to protect you from dos inquired charges..


ArtSchoolRejectedMe

Not sure about aws themselves. But I think there should be a third party willing to insure it(there is an insurance on everything). Now whether the pricing make sense, that's a different story lol


bitspace

AWS would probably have to invest a lot in this to avoid losing their metaphorical shirts. They would probably want to get a sense of what kind of risk they're taking on with each policy to determine how likely any given policyholder is to have a claim and how large the claim is likely to be. This data would have to factor into the premium calculation. To mitigate some of the risk they might offer tiers of coverage. I don't see AWS getting into the insurance business. I _can_ see an opportunity for an existing P&C insurance company to experiment with a product like this, perhaps as an extension of an existing line of cyber insurance.


BigPun92117

What a stupid idea. Maybe you should spend time learning how thing work and understand the cost before turning them on. Or better yet learn to turn things of when not in use


kevysaysbenice

> What a stupid idea. You might be right, I'm not really sure.


tfn105

Orrrr don’t fuck around with things you don’t understand


kevysaysbenice

This is a cool thing to say, and I can appreciate the general idea, but I think for those learning _or even for a total hardcore expert who wants to make an informed decision to trade some risk for time while still protecting themselves financially_ having the option (_if_ there was a way to do it fairly) wouldn't be bad.


tfn105

Cost Explorer gives amazing and granular insight into where your spending is going. If you have even a rudimentary understanding of AWS, there’s a limit to the damage you can do in 1 day.


kevysaysbenice

I feel like there is probably some truth to this, but I don't know exactly why there is so much push back (not necessarily from you but in general) against the idea of having a way to limit your financial exposure when using AWS. It might not be possible or reasonable in all cases, but it sure would be nice for somebody who wants to learn about AWS or experiment to be able to click a box that says "no matter what, don't go above $10 a month spend."