Skip to content

Instantly share code, notes, and snippets.

View manishtiwari25's full-sized avatar
💭
I may be slow to respond.

Manish Tiwari manishtiwari25

💭
I may be slow to respond.
View GitHub Profile
@manishtiwari25
manishtiwari25 / azure-compliance.json
Last active February 13, 2026 20:37
Azure Services Compliance Coverage Matrix | Based on Microsoft's official compliance offerings report from the Service Trust Portal | Last synced: 2026-02-13 20:37:13 UTC
{
"schemaVersion": "2.0",
"generatedAt": "2026-02-13T20:37:13Z",
"sourceDescription": "Microsoft Azure Compliance Offerings",
"frameworks": [
"CSA STAR Certification",
"CSA STAR Attestation",
"ISO 27001, 27018",
"ISO 27017",
"ISO 27701",
JsonSerializerOptions jsonSerializerOptions = new JsonSerializerOptions()
{
DefaultIgnoreCondition = JsonIgnoreCondition.WhenWritingNull
};
CosmosSystemTextJsonSerializer cosmosSystemTextJsonSerializer = new CosmosSystemTextJsonSerializer(jsonSerializerOptions);
CosmosClientOptions cosmosClientOptions = new CosmosClientOptions()
{
ApplicationName = "Test",
Serializer = cosmosSystemTextJsonSerializer
};
public class CosmosSystemTextJsonSerializer : CosmosSerializer
{
private readonly JsonObjectSerializer systemTextJsonSerializer;
public CosmosSystemTextJsonSerializer(JsonSerializerOptions jsonSerializerOptions)
{
this.systemTextJsonSerializer = new JsonObjectSerializer(jsonSerializerOptions);
}
public override T FromStream<T>(Stream stream)
@manishtiwari25
manishtiwari25 / Deploy.ps1
Last active August 9, 2023 17:35
Scripts to automate azure b2c custom policy deployment and validation, for more info (https://blogs.bitesinbyte.com/blogPost/a474c427-52d8-4f7d-9f65-02822fced323)
param(
[Parameter(Mandatory = $true)]
[string]$clientID,
[Parameter(Mandatory = $true)]
[string]$clientSecret,
[Parameter(Mandatory = $true)]
[string]$tenantId,
param(
[string]$storageAccount,
[string]$blobContainer,
[string]$instanceName,
[string]$databaseName,
[string]$storageKey
)
import-module sqlps;
$sqlPath = "sqlserver:\sql\$($env:COMPUTERNAME)"
@manishtiwari25
manishtiwari25 / wellKnow.proto
Created March 21, 2022 17:15
gRPC well know type example
syntax = "proto3"
import "google/protobuf/duration.proto";
import "google/protobuf/timestamp.proto";
import "google/protobuf/wrappers.proto"
message Meeting {
google.protobuf.StringValue subject = 1;
google.protobuf.Timestamp time = 2;
google.protobuf.Duration duration = 3;
@manishtiwari25
manishtiwari25 / scalarTypes.proto
Created March 21, 2022 17:09
scalar value types gRPC
syntax = "proto3"
message Something {
string subject = 1;
int32 id = 2;
float floatVar = 3;
}
@manishtiwari25
manishtiwari25 / world_currency_symbols.json
Last active February 13, 2026 20:46
List Of Countries With States And Other Useful Information, Updated On 02/13/2026 20:46:43
[
{
"Flag": "https://www.geonames.org/flags/x/ad.gif",
"CountryName": "Andorra",
"Currency": "Euro Member Countries",
"Code": "EUR",
"Symbol": "\u20AC",
"SymbolImage": "https://www.xe.com/symbols-page/symbols/curSymbol8364.gif"
},
{
@manishtiwari25
manishtiwari25 / country_state.json
Last active February 13, 2026 20:44
List Of Countries With States And Other Useful Information, Updated On 02/13/2026 20:44:44
[
{
"name": "Andorra",
"countryCode": "AD",
"countryCodeAlpha3": "AND",
"phone": "376",
"currency": "EUR",
"flag": "https://www.geonames.org/flags/x/ad.gif",
"symbol": "\u20AC",
"stateProvinces": [
@manishtiwari25
manishtiwari25 / SendMail.cs
Last active February 19, 2021 15:13
Send mail using O365 account c#
using System;
using System.Collections.Generic;
using System.Text.Json;
using System.Text.Json.Serialization;
using RestSharp;
public class Body
{
[JsonPropertyName("contentType")]
public string ContentType { get; set; }
[JsonPropertyName("content")]