If you want to export the key to another server, backup it and restore it.
Encryption by Cert
Since SQL Server 2005, there is one built-in function called hashbytes
please by aware if you define the string type as char and varchar , the hash varies.
so , here is one example
to be safe, using Rtrim on nchar type to get the same result vs the varchar one
C# and Sql, If you want to get the same hash for a given string, be sure to use the same encoding logic for the string, like Ascii vs Unicode.
in Java, try the commons-codec,
if you use nvarchar or nchar, make sure use unicde in c# also.
Sql server unicode
something in Java,switched it to unicdoe, follow the same byte orders
If you checked the code in HttpWebRequest by reflector, you might found it has a lot logging support code
sometimes, you do want to check the request behavior on sockets, http level, you can simply turn on the logging. here is a quick how,
change your config to somehow like this,
when you run the app with the httprequest request , you will see the detailed logging
There is one class called DigestUtils in the apache commons-codec, here is a quick how to start tutorial to pickup the jar and do a simple one way hash.
Add a dependency to commons-codec in your pom file
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" </dependencies> |
then update the project ,we can see the jar is included in the project
If you want included the jar in the dependenciy, add one plugin for the assembling
then mvn assembly:assembly you will see the jar with the inlined codec jar files.
<build> |
Got a New Nexus 7 (2013) modal, and it was stuck on the X logo forever, it’s fully charged.
my firs try is to restore to the factory image, however, no official image for “flo” the New nexus 7 in the Google page.
it only have the old one
https://developers.google.com/android/nexus/images?hl=de-DE
after did a lot Goggling, found this one works
http://droidbasement.com/asus/razor/flo/sys-backup/
fastboot boot recovery.img
then clear cache, install the zip for sdcard or sideload
then it will works, Good luck
To begin, log in as root and disable IPv6 by typing:
echo "install ipv6 /bin/true" > /etc/modprobe.d/disable-ipv6.conf
Now run the following command to disable ip6tables:
chkconfig ip6tables off
We must now disable any calls to IPv6 in its various locations. To do this we will start by opening the following configuration file:
vi /etc/sysconfig/network
Scroll down and add or amend the following line to read:
NETWORKING_IPV6=no
To complete this process, you must now modify the configuration for each Ethernet device to show the following values:
IPV6INIT=no
IPV6_AUTOCONF=no
after rebooting, you can tell no IPv6 address listed on the nic card
also lsmod|grep ipv6 returns nothing
for some cases, you may find it’s hard to debug the .net application exception using mdbg or cordbg. then windbg will be the good shoot.
you don’t need to download the full sdk to the production server, just go to http://windbg.org/, under the windbg quick links download the x86 or 64 bit debuggers which are less then 20M , install it on the server.
Now, let’s assume we have one bug application.
when we run the application, start the windbg, click attach to process(F6). then windbg is attached to the buggy application.
load the clr sos extension, and setup to break when there is one clr exception.
then the app will stop and breakpoint will be hit whenever there is one .net exception.
and we can use !clrstack to see the full stacktrace
!clrstack –a will show the arguments on each method call
besides the sxe, also we can use sxd, sxn and sxi