|
I have been working on a little dotnet core project that will allow users to create their own site and then post to it. It's really an interesting experiment so I can learn the underlying technologies -- and I've learned a ton so far.
Anyways, I just got my SSL Cert applied to my site so now it is secure for users :
https://NewLibre.com[^]
HTTPS & HTTP Still Work
The additionally interesting thing is that I updated the dotnet core site with the existing (and very limited prototype code) and everything is now working perfectly under HTTPS and still works under HTTP if the user selects that.
Cool VStudio Deployment
Mostly, I'm shocked that it still works. I'm also amazed at how easy VStudio 2017 and dotnet core make it to publish your web site. Serious CI and very cool. Also cool that you can test so easily on localhost:<port> then deploy to your prod site and it just works.
Well, I've recently posted in Weird & Wonderful about this site that will allow you to create a landing page (prototype) ==> The Weird and The Wonderful - dotnet core gen sub-web landing page[^]
And I've also written an article related to some other challenges I had:
DotNet Core 2.x Razor Pages: Using PartialViews[^]
And I documented a bug in Dotnet Core razor pages at : Why is my Model object always null on my Razor Page in dotnet core 2.x Razor Page app? - Stack Overflow[^]
|
|
|
|
|
|
Thanks for the encouragment.
RickZeeland wrote: I also wonder if you are using a reverse proxy server for your website ?
I'm not sure what that is.
Are you wondering how I can pull the daily Dilbert comic to your landing page on the fly? --ie How I can pull remote content? Or something else?
|
|
|
|
|
You can read about it here: Web server implementations in ASP.NET Core | Microsoft Docs[^]
I found it interesting for our company as there are multiple SignalR projects in the pipeline and that way the developers don't have to implement HTTPS security themselves in their applications (we always struggle with certificates and stuff like that )
|
|
|
|
|
Interesting. Thanks. I will take a look at that article.
EDIT
Oh, yes, interesting. On my main site I am not employing that at this time.
However, I have also deployed a test dotnet core web site to my DigitalOcean.com droplet (running Linux Debian). I want to soon try deploying this prototype to that environment but I had a heck of a time getting the sample running due to getting nginx (proxy) setup properly to expose it to the outside world.
|
|
|
|
|
I'm seeing a couple of 404 errors for your fallback scripts:
- https://newlibre.com/lib/jquery/dist/jquery.min.js
- https://newlibre.com/lib/bootstrap/dist/js/bootstrap.min.js
Firefox is displaying a "mixed content" warning, but I can't see what's causing it. Chrome, Edge and IE11 don't seem to have that problem.
(Edit: Now Firefox has stopped complaining about it as well. Weird.)
Did you have to pay for your certificate? Let's Encrypt[^] might have been a better option, especially if you could combine it with PKISharp/win-acme[^] to automate the renewals.
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|
|
Thanks for all that info.
Very nice.
I will check out those items.
I did pay for SSL cert but only $29 and then additional $24 for static IP which is required.
All hosted on smarterasp.net which is cheap and quite nice and allows direct deploy from VSTudio 2017.
|
|
|
|
|
One of the issues is that it pulls the image from Dilbert.com and there is no SSL version of Dilbert.com.
This shows that warning/error in firefox about images:
https://i.stack.imgur.com/90Xeh.png[^]
Thanks again.
|
|
|
|
|
congrats and a quick question ... :
did you encounter any problems with SignalR over https ?
I am asking because I could not make it (SignalR 2.2.3) work using (various types of)
self-signed certificates, no matter how hard I tried ...
|
|
|
|
|
Very good question. Unfortunately I have not tried it yet.
My signalr example runs from my raddev.us which doesn't have SSL on it (yet).
If I get a chance I will promote that test signalr app to my newlibre.com and test it out.
|
|
|
|
|
Sounds good ...
Configuring SignalR server for https with a self-signed cert was not a problem, but SignalR .Net client refused to connect ... JavaScript SignalR client will probably work, but it is not an option in my case, so I am stuck for a while ...
|
|
|
|
|
|
Quote: Stargazer, you with your head in the heavens,
You'll never get by walkin' that high off the ground.
Moon dreamer, I've been around and I've seen it;
The higher you get--the harder they let you down.
You pay your dues, it seems forever.
And if you're clever you may be in for a while,
Then you're out of style.
|
|
|
|
|
Hi All,
Guess what my companies favoured Goggle search is this PM, (shakes head, goes back to work)
|
|
|
|
|
How to grow those?
They'll grow in the used coffee ground from the office. Just fill a plastic cup with used coffee-grounds and plant 'em. Aw, and poke a hole in the bottom of the cup for drainage.
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
"If you just follow the bacon Eddy, wherever it leads you, then you won't have to think about politics." -- Some Bell.
|
|
|
|
|
Interesting, I was going to put mine in a Strawberry Jar my Mum found...
|
|
|
|
|
Seedlings do not like transparent pots; the soil will warm up more by the sunlight. Strawberry jars also lack a draining-point, so the roots of the seedling would be rotting pretty quickly. You need a way to get rid of excess water.
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
"If you just follow the bacon Eddy, wherever it leads you, then you won't have to think about politics." -- Some Bell.
|
|
|
|
|
|
glennPattonWork wrote: Guess what my companies favoured Goggle search is this PM
How to grow a Cream Bush?
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
|
|
I ended up following the link for the PHP bug and read the report. Then I scratched my head and wondered who decided to complicate date functions like that! So if I'm following the logic correctly...
- If the year is set to '00' in PHP, it apparently doesn't mean '0000', instead it is short hand for '2000'. So '00-00-00' means The year '2000', the month '00', and the day '00'.
- Okay, but the month can't be zero! '00' means you have to subtract one from the year, which makes the year '1999', and the month '12'. That gets us to '1999-12-00'
- Drat, day is also zero! Time to subtract a day from the month, '1999-11-30'
So now '00-00-00' == '1999-12-00' == '1999-11-30'! How much drinking was required before someone thought that was a good idea!?
|
|
|
|
|
Everyone hates on JS math but it actually makes some sense. The only difference between JS and C# in this respect is JS has defined the operator - for the additional string /string , string /int , and int /string combinations. My crude reference chart[^]. You can give C# the same behavior by implementing those missing combinations. Quick example:
class Integer
{
public int Value { get; set; }
public Integer() =>
Value = 0;
public Integer(int number) =>
Value = number;
public static Integer operator +(Integer d1, Integer d2) =>
new Integer(d1.Value + d2.Value);
public static string operator +(string s, Integer d) =>
s + d.Value;
public static string operator +(Integer d, string s) =>
d.Value + s;
public static Integer operator -(Integer d1, Integer d2) =>
new Integer(d1.Value - d2.Value);
public static Integer operator -(Integer d, string s) =>
new Integer(d.Value - int.Parse(s));
public static Integer operator -(string s, Integer d) =>
new Integer(int.Parse(s) - d.Value);
public static implicit operator int(Integer d) =>
d.Value;
public static implicit operator Integer(int d) =>
new Integer(d);
}
static void Main(string[] args)
{
string x = "5";
Integer y = 3;
Integer result1 = x + y - y;
Integer result2 = x - y + y;
Console.WriteLine($"Result1: {result1.Value}\nResult2: {result2.Value}");
Console.ReadKey();
}
EDIT: Simplified code example.
EDIT2: Accidentally left a return when compacting the code.
modified 26-Apr-18 12:38pm.
|
|
|
|
|
Another way of looking at it -
In Javascript:
50 apples * 30 oranges = 1500 of something or other.
In C:
50 apples * 30 oranges = "sorry, I'm not going to do that because it makes no sense and I don't want you to imagine that it does!"
98.4% of statistics are made up on the spot.
|
|
|
|
|