Expense tracker #62829 just dropped. Who asked?

>not trying to sound elitist but
>every time I doomscroll, there's a new expense tracker
>starter pack: add expense, select category, throw in fancy charts

>why tho?

>no one in their right mind logs expenses manually
>life is already boring.

>these apps aren't solutions, they're band-aids over existential dread

>every transaction already goes through the bank
>just give us one simple API to fetch them
>would instantly wipe out the TODO app epidemic

>went to check my bank transactions
>can't paste password
>"for security" lol okay
>I use a password manager
>had to open inspect element and inject it manually
>facepalm.png

>banks need to do better


Share:

SPF check for our simple SMTP receiver

 Why?

> bored.


The issue:

> Alice connects to my server because she wants to send an email to bob@myserver.com  
> She sets the FROM header to alice@gmail.com  
> Says it's from Gmail  
> I have no way to know if it actually came from Gmail  
> Need a way to verify it
 

SPF: 

> I ask Gmail for a list of IP addresses they send email from  
> To get that info, I need to query the TXT record for the gmail.com domain  
> I find "v=spf1 redirect=_spf.google.com"  
> Another TXT record query for _spf.google.com  
> I find "v=spf1 include:_netblocks.google.com include:_netblocks2.google.com include:_netblocks3.google.com ~all"  
> Here we go again  
> Query all three netblocks  
> Finally get:  
> "v=spf1 ip4:35.190.247.0/25 ip4:64.233.160.0/19 ip4:66.102.0.0/20 ip4:66.249.80.0/20 ip4:72.14.192.0/18 ip4:74.125.0.0/16 ip4:108.177.8.0/21 ip4:173.194.0.0/16 ip4:209.85.128.0/17 ip4:216.58.192.0/19 ip4:216.239.32.0/19 ~all"  
> Once I get the IP ranges, I can finally compare the sender’s IP  

> this is how the SPF works  
> now i used pydig to recursively gather the ip ranges  
> compared it with the client ip  
> implemented spf validation  
> find it here  
> https://github.com/naveen17797/simple-smtp-receiver/releases/tag/implement-spf  

> No more forged emails

> Bye


 

Share:

SMTP mail receiver from scratch -

 Why?

> felt like i lost my curiosity

> less free time / number of pigeons to take care of

> wanted to build something new

 

Objective

>  A program which can receive email

 

What i don't want

- validation code

- multiple threads

- authentication stuff

 

How does it work:

- client connects to server and sends a command

- each command gets acknowledged by server with a success code

- if something raises error, then the connection gets dropped.

 

Source:

https://github.com/naveen17797/simple-smtp-receiver/releases/tag/init (LLM Generated code)

 

Stuff i found interesting:

> The SMTP server uses . (dot) as a signal to stop receiving DATA part of the email

> So if i manage to put a dot in a newline on email body, this will probably strip the email up to that part.

> How does SMTP prevents that from happening?

> When you send a dot on new line in the email, SMTP client automatically adds a dot and server removes them upon receiving it.

 

 

Share: