Weird: Very confusing Base64 problem (includes quiz)
-
Do you see what is wrong with the Base64 encoded data (below)?* *Find answer at bottom of this entry. Also, don't try decoding the data because it is non-sense because it is base64 of encrypted data. Had a problem where my Base64 data (all of a sudden) was being corrupted. However, it is very subtle (see ANSWER at bottom). HINT: Just one char was being corrupted. Data Only Corrupted After Posting I couldn't understand this. The data (before I posted it was completely fine). Only after posting data did it get corrupted (and it's not a URL-encoding thing). Actually, that is incorrect. The data is posted to the web site & saved in DB with no corruption. Only after the data is returned as a part of a JSON object is the base64 data corrupted. CRazy!! :confused: I Finally Found This Argument At Github - Spoiler ALERT!! + sign is changing into \u002B using JsonSerializer.Serialize · Issue #35281 · dotnet/runtime · GitHub[^] This is a very WEIRD (and obscure) thing. I can't believe I finally figured this out. Now, I will have to implement a fix. Discovering the problem was extremely difficult because the base64 data is upwards of 40K. Have any of you seen this?
jHx4uha8sCRyiqv8nRVJpRoQPx45ghciXg6PJb8qrxORwmMTN6cLlDIh4PVZenZvh3saEtlGAxZlI2Wm\u002BumDIiIs/r9vU5XgnMMF\u002Bk5TnvzNSLvYaTY41mS4FNZ8yshdVFn\u002Bq2UolJzz8ldlycDW1a7JfWKS88XNaBVgbZYjrSquDjCHOwIY8yGzxHnv70BDHEgHz6IUtZ7gEzKQ/dlVabYe7D2/QfU0Mtobx/LVkxa/oiujTaoiCLIQdkmALGbQqj/rtdLlOzKWjqLMpa/EhwGTA5unrEJMR\u002BDgKIJ5kxwoffKwVeydXlz1GY9WcyJrFf1xJr2CmKhUsbbXQQ0Qcgi80FJcupEQr\u002Bd4jclGeVbyFla40Ncm7ZjDeRVQ5coP2n1VyHTosWpvk7WqDIv1URbD8Xx3qfrXr2LsbS\u002Bzhe67bXNv4wekJfkvfxY8dh4Qjz9ZW0PBwIgW6KdtmCEKsURRWl5m8OvLxkL8iWuXwG\u002BdQeTSJb0Ew/AohuSpuiSeV5REkEagMoGnHdV6sLGo8kselY4sh1SqtIdoRq5E6nO60V7kzcCfm4MgdmwWEuRRxtJeeEl59dDvvOOOefbYCHLWGONVQ4/hpLPxnU2beyPoz7j9oWz2hIMgjTlQgzupzIZzjdzu7O62PDRorm8rVnZAmLFnNbAmFCzpgLsB1HZrTL5/MXeEdUz2WuKjJPAi4q\u002BnPddo0xm6bkvKXoGWJbwFAoxaWD7hffcvuurAkIqPH2S8CgP3cmnLiM6Qg65k7Sy51T81ab92g92rBJ\u002B8BFVPCDVdGsy6BblFP2/KQ6\u002BoCllRD\u002BIqNqIfdfzmJUp2WEEpviwP\u002B9IhGuGC2flCrMclKaAmTuZLyijgQkC2\u002BEb7hU5GoA8h5ic3hOFSOhmUo20/LIiIIj3jUanfxJLLW6MTY3c5WNJlNUz0ucwGRUNqO2VMxsPnWp05M3aGU4kxYIracZwmvqeQKgGX59vhPo5GhmFxZroVkSO7\u002BEOWRG/J1et/5dFslN3dZDLFSIBvrA5pJF7BuEZPsbcWTOWxnrWZl\u002BeGouVoC8Kf
-
Do you see what is wrong with the Base64 encoded data (below)?* *Find answer at bottom of this entry. Also, don't try decoding the data because it is non-sense because it is base64 of encrypted data. Had a problem where my Base64 data (all of a sudden) was being corrupted. However, it is very subtle (see ANSWER at bottom). HINT: Just one char was being corrupted. Data Only Corrupted After Posting I couldn't understand this. The data (before I posted it was completely fine). Only after posting data did it get corrupted (and it's not a URL-encoding thing). Actually, that is incorrect. The data is posted to the web site & saved in DB with no corruption. Only after the data is returned as a part of a JSON object is the base64 data corrupted. CRazy!! :confused: I Finally Found This Argument At Github - Spoiler ALERT!! + sign is changing into \u002B using JsonSerializer.Serialize · Issue #35281 · dotnet/runtime · GitHub[^] This is a very WEIRD (and obscure) thing. I can't believe I finally figured this out. Now, I will have to implement a fix. Discovering the problem was extremely difficult because the base64 data is upwards of 40K. Have any of you seen this?
jHx4uha8sCRyiqv8nRVJpRoQPx45ghciXg6PJb8qrxORwmMTN6cLlDIh4PVZenZvh3saEtlGAxZlI2Wm\u002BumDIiIs/r9vU5XgnMMF\u002Bk5TnvzNSLvYaTY41mS4FNZ8yshdVFn\u002Bq2UolJzz8ldlycDW1a7JfWKS88XNaBVgbZYjrSquDjCHOwIY8yGzxHnv70BDHEgHz6IUtZ7gEzKQ/dlVabYe7D2/QfU0Mtobx/LVkxa/oiujTaoiCLIQdkmALGbQqj/rtdLlOzKWjqLMpa/EhwGTA5unrEJMR\u002BDgKIJ5kxwoffKwVeydXlz1GY9WcyJrFf1xJr2CmKhUsbbXQQ0Qcgi80FJcupEQr\u002Bd4jclGeVbyFla40Ncm7ZjDeRVQ5coP2n1VyHTosWpvk7WqDIv1URbD8Xx3qfrXr2LsbS\u002Bzhe67bXNv4wekJfkvfxY8dh4Qjz9ZW0PBwIgW6KdtmCEKsURRWl5m8OvLxkL8iWuXwG\u002BdQeTSJb0Ew/AohuSpuiSeV5REkEagMoGnHdV6sLGo8kselY4sh1SqtIdoRq5E6nO60V7kzcCfm4MgdmwWEuRRxtJeeEl59dDvvOOOefbYCHLWGONVQ4/hpLPxnU2beyPoz7j9oWz2hIMgjTlQgzupzIZzjdzu7O62PDRorm8rVnZAmLFnNbAmFCzpgLsB1HZrTL5/MXeEdUz2WuKjJPAi4q\u002BnPddo0xm6bkvKXoGWJbwFAoxaWD7hffcvuurAkIqPH2S8CgP3cmnLiM6Qg65k7Sy51T81ab92g92rBJ\u002B8BFVPCDVdGsy6BblFP2/KQ6\u002BoCllRD\u002BIqNqIfdfzmJUp2WEEpviwP\u002B9IhGuGC2flCrMclKaAmTuZLyijgQkC2\u002BEb7hU5GoA8h5ic3hOFSOhmUo20/LIiIIj3jUanfxJLLW6MTY3c5WNJlNUz0ucwGRUNqO2VMxsPnWp05M3aGU4kxYIracZwmvqeQKgGX59vhPo5GhmFxZroVkSO7\u002BEOWRG/J1et/5dFslN3dZDLFSIBvrA5pJF7BuEZPsbcWTOWxnrWZl\u002BeGouVoC8Kf
-
Roger, I'm sure that you've figured this out by now. That escaping behavior is actually in the JSON specification. RFC 8259 - Section 7[^]
Yeah, it seems like it is a normal thing. It seems that it was just altering a test I had (that didn't parse it as json) that used the base64 encoded data and that is where I was seeing the issue. It's part of a larger challenge so it looks like it was a false-positive for me. Thanks
-
Do you see what is wrong with the Base64 encoded data (below)?* *Find answer at bottom of this entry. Also, don't try decoding the data because it is non-sense because it is base64 of encrypted data. Had a problem where my Base64 data (all of a sudden) was being corrupted. However, it is very subtle (see ANSWER at bottom). HINT: Just one char was being corrupted. Data Only Corrupted After Posting I couldn't understand this. The data (before I posted it was completely fine). Only after posting data did it get corrupted (and it's not a URL-encoding thing). Actually, that is incorrect. The data is posted to the web site & saved in DB with no corruption. Only after the data is returned as a part of a JSON object is the base64 data corrupted. CRazy!! :confused: I Finally Found This Argument At Github - Spoiler ALERT!! + sign is changing into \u002B using JsonSerializer.Serialize · Issue #35281 · dotnet/runtime · GitHub[^] This is a very WEIRD (and obscure) thing. I can't believe I finally figured this out. Now, I will have to implement a fix. Discovering the problem was extremely difficult because the base64 data is upwards of 40K. Have any of you seen this?
jHx4uha8sCRyiqv8nRVJpRoQPx45ghciXg6PJb8qrxORwmMTN6cLlDIh4PVZenZvh3saEtlGAxZlI2Wm\u002BumDIiIs/r9vU5XgnMMF\u002Bk5TnvzNSLvYaTY41mS4FNZ8yshdVFn\u002Bq2UolJzz8ldlycDW1a7JfWKS88XNaBVgbZYjrSquDjCHOwIY8yGzxHnv70BDHEgHz6IUtZ7gEzKQ/dlVabYe7D2/QfU0Mtobx/LVkxa/oiujTaoiCLIQdkmALGbQqj/rtdLlOzKWjqLMpa/EhwGTA5unrEJMR\u002BDgKIJ5kxwoffKwVeydXlz1GY9WcyJrFf1xJr2CmKhUsbbXQQ0Qcgi80FJcupEQr\u002Bd4jclGeVbyFla40Ncm7ZjDeRVQ5coP2n1VyHTosWpvk7WqDIv1URbD8Xx3qfrXr2LsbS\u002Bzhe67bXNv4wekJfkvfxY8dh4Qjz9ZW0PBwIgW6KdtmCEKsURRWl5m8OvLxkL8iWuXwG\u002BdQeTSJb0Ew/AohuSpuiSeV5REkEagMoGnHdV6sLGo8kselY4sh1SqtIdoRq5E6nO60V7kzcCfm4MgdmwWEuRRxtJeeEl59dDvvOOOefbYCHLWGONVQ4/hpLPxnU2beyPoz7j9oWz2hIMgjTlQgzupzIZzjdzu7O62PDRorm8rVnZAmLFnNbAmFCzpgLsB1HZrTL5/MXeEdUz2WuKjJPAi4q\u002BnPddo0xm6bkvKXoGWJbwFAoxaWD7hffcvuurAkIqPH2S8CgP3cmnLiM6Qg65k7Sy51T81ab92g92rBJ\u002B8BFVPCDVdGsy6BblFP2/KQ6\u002BoCllRD\u002BIqNqIfdfzmJUp2WEEpviwP\u002B9IhGuGC2flCrMclKaAmTuZLyijgQkC2\u002BEb7hU5GoA8h5ic3hOFSOhmUo20/LIiIIj3jUanfxJLLW6MTY3c5WNJlNUz0ucwGRUNqO2VMxsPnWp05M3aGU4kxYIracZwmvqeQKgGX59vhPo5GhmFxZroVkSO7\u002BEOWRG/J1et/5dFslN3dZDLFSIBvrA5pJF7BuEZPsbcWTOWxnrWZl\u002BeGouVoC8Kf
Gads, I remember dealing with a similar issue. Turned out the issue was that the front-end wasn't using
encodeURIComponent
in the utility app for setting password.
Latest Article:
Create a Digital Ocean Droplet for .NET Core Web API with a real SSL Certificate on a Domain -
Do you see what is wrong with the Base64 encoded data (below)?* *Find answer at bottom of this entry. Also, don't try decoding the data because it is non-sense because it is base64 of encrypted data. Had a problem where my Base64 data (all of a sudden) was being corrupted. However, it is very subtle (see ANSWER at bottom). HINT: Just one char was being corrupted. Data Only Corrupted After Posting I couldn't understand this. The data (before I posted it was completely fine). Only after posting data did it get corrupted (and it's not a URL-encoding thing). Actually, that is incorrect. The data is posted to the web site & saved in DB with no corruption. Only after the data is returned as a part of a JSON object is the base64 data corrupted. CRazy!! :confused: I Finally Found This Argument At Github - Spoiler ALERT!! + sign is changing into \u002B using JsonSerializer.Serialize · Issue #35281 · dotnet/runtime · GitHub[^] This is a very WEIRD (and obscure) thing. I can't believe I finally figured this out. Now, I will have to implement a fix. Discovering the problem was extremely difficult because the base64 data is upwards of 40K. Have any of you seen this?
jHx4uha8sCRyiqv8nRVJpRoQPx45ghciXg6PJb8qrxORwmMTN6cLlDIh4PVZenZvh3saEtlGAxZlI2Wm\u002BumDIiIs/r9vU5XgnMMF\u002Bk5TnvzNSLvYaTY41mS4FNZ8yshdVFn\u002Bq2UolJzz8ldlycDW1a7JfWKS88XNaBVgbZYjrSquDjCHOwIY8yGzxHnv70BDHEgHz6IUtZ7gEzKQ/dlVabYe7D2/QfU0Mtobx/LVkxa/oiujTaoiCLIQdkmALGbQqj/rtdLlOzKWjqLMpa/EhwGTA5unrEJMR\u002BDgKIJ5kxwoffKwVeydXlz1GY9WcyJrFf1xJr2CmKhUsbbXQQ0Qcgi80FJcupEQr\u002Bd4jclGeVbyFla40Ncm7ZjDeRVQ5coP2n1VyHTosWpvk7WqDIv1URbD8Xx3qfrXr2LsbS\u002Bzhe67bXNv4wekJfkvfxY8dh4Qjz9ZW0PBwIgW6KdtmCEKsURRWl5m8OvLxkL8iWuXwG\u002BdQeTSJb0Ew/AohuSpuiSeV5REkEagMoGnHdV6sLGo8kselY4sh1SqtIdoRq5E6nO60V7kzcCfm4MgdmwWEuRRxtJeeEl59dDvvOOOefbYCHLWGONVQ4/hpLPxnU2beyPoz7j9oWz2hIMgjTlQgzupzIZzjdzu7O62PDRorm8rVnZAmLFnNbAmFCzpgLsB1HZrTL5/MXeEdUz2WuKjJPAi4q\u002BnPddo0xm6bkvKXoGWJbwFAoxaWD7hffcvuurAkIqPH2S8CgP3cmnLiM6Qg65k7Sy51T81ab92g92rBJ\u002B8BFVPCDVdGsy6BblFP2/KQ6\u002BoCllRD\u002BIqNqIfdfzmJUp2WEEpviwP\u002B9IhGuGC2flCrMclKaAmTuZLyijgQkC2\u002BEb7hU5GoA8h5ic3hOFSOhmUo20/LIiIIj3jUanfxJLLW6MTY3c5WNJlNUz0ucwGRUNqO2VMxsPnWp05M3aGU4kxYIracZwmvqeQKgGX59vhPo5GhmFxZroVkSO7\u002BEOWRG/J1et/5dFslN3dZDLFSIBvrA5pJF7BuEZPsbcWTOWxnrWZl\u002BeGouVoC8Kf
Think that's because Json had a quarrel with the Argonauts some time ago :-\
-
Think that's because Json had a quarrel with the Argonauts some time ago :-\
-
Ah, learned something new, should have known that being Dutch:
Quote:
In matters of commerce the fault of the Dutch Is offering too little and asking too much
:-\