$ uname -r
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# Issue: LinuxClient makes use of openssl 1 | |
# https://clients.amazonworkspaces.com/linux-install | |
# | |
cd ~/Downloads | |
wget wget http://security.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2.16_amd64.deb | |
# if the above doesn't works, go to http://security.ubuntu.com/ubuntu/pool/main/o/openssl/ and find another package | |
# that start like 'libssl1.1_1.1.1f-1ubuntu |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// Controller placed in mvc client project | |
// | |
public class AccountController : Controller | |
{ | |
[Authorize(Roles = "support")] | |
public IActionResult Impersonate(Guid id) | |
{ | |
if (id == Guid.Empty) | |
return BadRequest(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static class EnumHelper | |
{ | |
public static string Description(this Enum value) | |
{ | |
FieldInfo fi = value.GetType().GetField(value.ToString()); | |
DescriptionAttribute[] attributes = (DescriptionAttribute[])fi.GetCustomAttributes(typeof(DescriptionAttribute), false); | |
return attributes.Length > 0 ? attributes[0].Description : value.ToString(); | |
} | |
public static List<EnumDrop<T>> EnumerateDrop<T>() where T : Enum |