Is there any difference in using smtps instead of smtp? - comparison

Or is it transparent for the application layer ?
I ask this because I'm trying to connect to a smtps and no success
(smtp is working fine)

According to wikipedia it's transparent to the application layer, since its
no protocoll and no smtp-extension. It does it job perfectly transparent on
the transport layer.
K

Related

Block URLs using NetworkExtension

I'm trying to add some content filtering into my iOS app. Namely, I'd like if it could block certain URLs. I've poked around with some VPN stuff, but I'm getting lost. My basic understanding is that I need to create a Personal VPN using NetworkExtension and then I'll still need a server to point to where the content filtering will actually happen.
Other than that I've seen some mention of using a custom VPN to do the filtering on the client side (on the iPhone / iPad). I've ruled out using a content filter, as that only works for monitored devices.
What I'm trying to get more info on is:
How do I create a personal or custom VPN?
How do I spin up a server to filter this content? Could I use aws lambda?
I've read through all of these:
https://kean.blog/post/vpn-configuration-manager
https://stackoverflow.com/a/58992921/3320342
https://developer.apple.com/forums/thread/96777
https://developer.apple.com/forums/thread/74464?answerId=218089022#218089022
But I'm still stumped. Any pointing in the right direction would be greatly appreciated.

How to update a web page from requests made by another client (in rails)?

Here is my need:
I have to displays some information from a web page.
The web browser is actually on the same machine (localhost).
I want the data to be updated dynamically by the server initiative.
Since HTTP protocol is actually a request/response protocol, I know that to get this functionality, the connection between the server and the client (which is local here) should be kept open in some way (Websocket, Server-Sent Events, etc..)
Yes, "realtime" is really a fashion trend nowadays and there are many frameworks out there to do this (meteor, etc...)
And indeed, it seems that Rails supports this functionnality too in addition to using Websockets (Server-Sent Events in Rails 4 and ActionCable in Rails 5)
So achieving this functionnality would not be a big deal, I guess...
Nevertheless what I really want is to trigger an update of the webpage (displayed here locally) from a request made by another client..
This picture will explain that better :
At the beginning, the browser connects to the (local) server (green arrows).
I guess that a thread is executed where all the session data (instance variables) are stored.
In order to use some "realtime" mechanisms, the connection remains open and therefore the thread Y is not terminated. (I guess this is how it works)
A second user is connecting (blue arrows) to the server (could be or not be the same web page) and make some actions (eg. posting a form).
Here the response to that external client does not matter. Just an HTTP OK response is fine. But a confirmation web page could also be returned.
But in anyway the thread X (and/or the connection) has no particular reason to be kept.
Ok, here is my question (BTW thank you for reading me thus far).
How can I echo this new data on the local web browser ?
I see 2 differents ways to do this :
Path A: Before terminating, the thread X passes the data (its instance variables) to the thread Y which has its connection still open. Thus the server is able to update the web browser.
Path B: Before terminating the thread X sends a request (I mean a response since it is the server) directly to the web browser using a particular socket.
Which mechanisms should I use in either method to achieve this functionnality ?
For method A, how can I exchange data between threads ?
For method B, how can I use an already opened socket ?
But which of these two methods (or another one) is actually the best way to do that?
Again thank you for reading me thus far, and sorry for my bad english.
I hope I've been clear enough to expose my need.
You are overthinking this. There is no need to think of such low-level mechanisms as threads and sockets. Most (all?) pub-sub live-update tools (ActionCable, faye, etc.) operate in terms of "channels" and "events".
So, your flow will look like this:
Client A (web browser) makes a request to your server and subscribes to events from channel "client-a-events" (or something).
Client B (the other browser) makes a request to your server with instructions to post an event to channel "client-a-events".
Pub-sub library does its magic.
Client A gets an update and updates the UI accordingly.
Check out this intro guide: Action Cable Overview.

Website screen capture on Linux server

I have a webpage written in AngularJS that needs to be turned into an image and sent as an email once a week to clients. The webpage is on S3 and my backend server is written partly in Rails and partly in Node. Any ideas how to do this?
You can use something like PhantomJS (or based on Phantom CasperJS) - this is library like Selenium, headless browser. Possible to create screenshots with different device resolution and User-Agent. http://phantomjs.org/screen-capture.html

JavaFX webview set Proxy

I'm using a JavaFX webview in my application. Inside of it I load a local html file, which itself loads some javascript library from maps.google.com and then displays a google map with some markers inside the webview.
Now according to this question if I want to use a proxy I should just do:
System.setProperty("http.proxyHost","proxy.esrf.fr");
System.setProperty("http.proxyPort","3128");
But this has no effect. I can set whatever I want as the host and port. The google map tiles are still loaded, even if the settings are no valid proxy. So apparently it is not making use of the proxy settings.
How can I make sure, that all web traffic within the WebView is going via the proxy.
I also set the https.proxyHost and https.proxyPort by the way, just in case.
Thanks!
The problem was cause by a bugfix I did earlier.
When working with proxies in java this post is quite helpful. In the end it recommends setting
ProxySelector.setDefault(null);
to avoid issue with sockets and proxies.
However, this made setting the proxy via
System.setProperty("http.proxyHost","proxy.esrf.fr");
System.setProperty("http.proxyPort","3128");
impossible. Actually, it wasn't possible to set any proxy at all except by passing a Proxy object to URL.openConnection(Proxy p);
So instead of setting the default ProxySelector to null, I recommend setting
ProxySelector.setDefault(ProxySelector.getDefault());

Delphi how to avoid sniffers

I'm developing a project with Delphi 2010, at some point this project connects to internet and send some data to a php file via POST/IDHTTP, those parameters encrypted with aes and as you know there is no way to get source code of php files via browser. But when i use sniffer on my project sniffer software shows full path of php file and parameters. I was wondering is there any chance to hide path and parameters with IDHTTP. For example when i try on Skype sniffer only shows decimal characters on skype's transmission. Is it possible to do same or totally hide the traffic ?
Thanks in advance.
You can use HTTPS, it is supposed to be standard way to transmit HTTP traffic through SSL-protected channel. Example of code you can find for example here.
In addition to Andrei's answer, you can consider encrypting your traffic on-top of using HTTPS.
In other words,
1) Use HTTPS protocol.
2) Add your own layer of encryption to encrypt all data coming to and from your server.
In addition to HTTPs and encrypted data, you can also add security by using client certificates. See https://security.stackexchange.com/questions/3605/certificate-based-authentication-vs-username-and-password-authentication
The answers explain the advantages of using CBA, one of them is
certificate usage never involves revealing any secret data to the
peer, so an attacker impersonating the server cannot learn anything of
value that way

Resources