5: Input/output error Error: Failure while executing; `/bin/launchctl bootstrap gui/502 and FATAL: password authentication failed for user

This is what I did to resolve on my Mac. Looked at the postgres.log cat /usr/local/var/log/postgres.log | tail -100 Found the following error on my logs FATAL: lock file “postmaster.pid” already exists Fix above PID issue and restart the server. rm /usr/local/var/postgres/postmaster.pid brew services restart postgresql

Generating a strong password in C#?

I just tried the following in linqpad: System.Web.Security.Membership.GeneratePassword(25, 10) This is the password I got: [XTJ_67g.i/ag1rL)6_Yv>*+% Or, if that’s not secure enough, try this: System.Web.Security.Membership.GeneratePassword(128, 100) which got me the following when running it three times: |c^.:?m)#q+(]V;}[Z(})/?-;$]+@!|^/8*_9.$&.&!(?=^!Wx?[@%+&-@b;)>N;&+*w[>$2+_$%l;+h+#zhs^{e?&=*(}X_%|:}]]}*X[+)Er%J/-=;Q0{:+=%c7:^$ /:_)hxF+*){2|;(>:*N^+!_&|}B.$})?[V=[+v({-:-@9-Z$j?.[-}(@MHx+}(}Mz_S(7#4}{..>@G|!+++{+C=|_}=+r^@&$0;L*|kz-;$++/N3$=}?;%&]]*/^#^!+ :*{]-x^$g{|?*))_=B@^.#%L;g|+)#[nq}?y(_(m;]S^I$*q=l-[_/?}&-!k^(+[_{Z|&:^%!_)!=p%=)=wYd-#.UP$%s1{*l%+[%?!c+7=@=.;{+M)!^}&d/]{];(&} this took way less than a second, btw. The framework is your friend. See http://msdn.microsoft.com/en-us/library/system.web.security.membership.generatepassword.aspx

Generate temporary URL to reset password

Probably the easiest way is going to be to modify your users table to add 2 extra columns, OR if you don’t want to modify the existing table you could add a new dependent table called “UserPasswordReset” or something like that. The columns are like this: PasswordResetToken UNIQUEIDENTIFIER, PasswordResetExpiration DATETIME If you go with the … Read more

Regex to find 3 out of 4 conditions

It’s not much of a better solution, but you can reduce [^a-zA-Z0-9] to [\W_], since a word character is all letters, digits and the underscore character. I don’t think you can avoid the alternation when trying to do this in a single regex. I think you have pretty much have the best solution. One slight … Read more

tech