code: func (ssa *SQLStorageAuthority) RevokeAuthorizationsByDomain(ctx context.Context, ident core.AcmeIdentifier) (int64, int64, error) {
  	identifierJSON, err := json.Marshal(ident)
  	if err != nil {
  		return 0, 0, err
  	}
  	identifier := string(identifierJSON)
  	results := []int64{0, 0}
  
  	now := ssa.clk.Now()
  	for i, table := range authorizationTables {
  		for {
  			authz, err := getAuthorizationIDsByDomain(ssa.dbMap.WithContext(ctx), table, identifier, now)
  			if err != nil {
  				return results[0], results[1], err
  			}
  			numAuthz := len(authz)
  			if numAuthz == 0 {
  				break
  			}
  
  			numRevoked, err := revokeAuthorizations(ssa.dbMap.WithContext(ctx), table, authz)
  			if err != nil {
  				return results[0], results[1], err
  			}
  			results[i] += numRevoked
  			if numRevoked < int64(numAuthz) {
  				return results[0], results[1], fmt.Errorf("Didn't revoke all found authorizations")
  			}
  		}
  	}
  
  	return results[0], results[1], nil
  }
docs: // RevokeAuthorizationsByDomain invalidates all pending or finalized authorizations
  // for a specific domain